Skip to content
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

Fix/ sort by categorical variables #1266

Merged
merged 5 commits into from Apr 19, 2024
Merged

Fix/ sort by categorical variables #1266

merged 5 commits into from Apr 19, 2024

Conversation

buckhalt
Copy link
Member

@buckhalt buckhalt commented Apr 18, 2024

Users have been able to configure rules for sorting by categorical variables in Architect, but they were being sorted as strings. This PR fixes sorting functionality for categorical variables to actually sort by the values provided.

The hierarchy for sorting is determined by the order that the values are defined in the variable definition. This user-supplied hierarchy is assumed to be high to low, to maintain consistency with the hierarchy sort used currently for sorting by ordinal variables.

In cases of items having multiple values in a category array, presence of a category is ranked higher than absence of. For instance [“A”, “B”] is considered higher in the hierarchy than [“A”].

@buckhalt buckhalt changed the title Fix/sort order feature/ sort by categorical variables Apr 19, 2024
@buckhalt buckhalt changed the title feature/ sort by categorical variables Fix/ sort by categorical variables Apr 19, 2024
@buckhalt buckhalt marked this pull request as ready for review April 19, 2024 15:00
@buckhalt buckhalt requested a review from jthrilly April 19, 2024 15:07
@buckhalt buckhalt changed the base branch from master to release/6.5.3 April 19, 2024 16:36
@buckhalt buckhalt merged commit bfa31dc into release/6.5.3 Apr 19, 2024
4 checks passed
@buckhalt buckhalt mentioned this pull request Apr 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant