Skip to content

add sort_categories argument #1

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

Conversation

chris-b1
Copy link

No description provided.


.. versionadded:: 0.19.0

Parameters
----------
to_union : list-like of Categoricals
sort_categories : boolean, default False
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would just call this sort

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Isn't that kind of ambiguous as to whether it will sort the categories or the values in the resulting Categorical?

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I also prefer sort_categories to be explicit.

BTW, I recommend @chris-b1 to open a separate PR on pandas master for open discussion.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sure once you merge pandas-dev#13763, I can submit as a standalone PR

@sinhrks sinhrks force-pushed the union_categoricals_ordered branch from 0971621 to 9cadc4e Compare July 25, 2016 22:49
@sinhrks sinhrks closed this Jul 29, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants