-
Notifications
You must be signed in to change notification settings - Fork 292
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[FIX] Remove unused levels from categorical index (#473)
If `unique_id` is categorical, and some levels were removed, then `value_counts()` in `_grouped_array_from_df()` still returns these levels in the output with their counts being 0. `_grouped_array_from_df()`, however, does not expect that some counts could be zero, therefore, it makes sense to drop unused levels from a categorical index.
- Loading branch information
Showing
2 changed files
with
10 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters