-
Notifications
You must be signed in to change notification settings - Fork 31
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
retain previous behaviour for tree-tables, it doesn't make sense as they are parent/child not groups #1831
Comments
4 tasks
Need a hotfix for V+ |
mofojed
added a commit
to mofojed/web-client-ui
that referenced
this issue
Mar 5, 2024
- If a table has no grouped columns or only one grouped column, no point in adding an extra Group column for that situation as it is just duplicate information - Fixes deephaven#1831 - Added unit tests, and tested with the following snippet: ```python from deephaven import read_csv, agg from deephaven.constants import NULL_INT from deephaven import empty_table _source = empty_table(100).update_view(["ID = i", "Parent = i == 0 ? NULL_INT : (int)(i / 4)"]) _insurance = read_csv("https://media.githubusercontent.com/media/deephaven/examples/main/Insurance/csv/insurance.csv") agg_list = [agg.avg(cols=["bmi", "expenses"])] small_by_list = ["region"] by_list = ["region", "age"] no_group_tree = _source.tree(id_col="ID", parent_col="Parent") no_group_agg = insurance.rollup(aggs=agg_list, by=small_by_list, include_constituents=True) group_rollup_no_agg = insurance.rollup(aggs=[], by=by_list, include_constituents=True) group_rollup_agg = insurance.rollup(aggs=agg_list, by=by_list, include_constituents=True) ```
mofojed
added a commit
that referenced
this issue
Mar 6, 2024
- If a table has no grouped columns or only one grouped column, no point in adding an extra Group column for that situation as it is just duplicate information - Fixes #1831 - Fixes #1853 - Added unit tests, and tested with the following snippet: ```python from deephaven import read_csv, agg from deephaven.constants import NULL_INT from deephaven import empty_table _source = empty_table(100).update_view(["ID = i", "Parent = i == 0 ? NULL_INT : (int)(i / 4)"]) _insurance = read_csv("https://media.githubusercontent.com/media/deephaven/examples/main/Insurance/csv/insurance.csv") agg_list = [agg.avg(cols=["bmi", "expenses"])] small_by_list = ["region"] by_list = ["region", "age"] no_group_tree = _source.tree(id_col="ID", parent_col="Parent") no_group_agg = _insurance.rollup(aggs=agg_list, by=small_by_list, include_constituents=True) group_rollup_no_agg = _insurance.rollup(aggs=[], by=by_list, include_constituents=True) group_rollup_agg = _insurance.rollup(aggs=agg_list, by=by_list, include_constituents=True) ```
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
No description provided.
The text was updated successfully, but these errors were encountered: