MaxRowsPerGroupPerID#
from tmlt.analytics import MaxRowsPerGroupPerID
- class tmlt.analytics.MaxRowsPerGroupPerID(grouping_column, max)#
Bases:
Constraint
A constraint limiting rows per unique (ID, grouping column) pair in a table.
For example,
MaxRowsPerGroupPerID("group_col", 5)
guarantees that each ID appears in at most five rows for each distinct value ingroup_col
.- __post_init__()#
Check constructor arguments.