Skip to content

CLN: remove ensure_categorical #33495

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

Merged
merged 6 commits into from
Apr 17, 2020
Merged

Conversation

jbrockmendel
Copy link
Member

only used in two places, its a misnomer because it really only ensures categorical dtype, and it complicates the dependency structure

Copy link
Member

@jorisvandenbossche jorisvandenbossche left a comment

Choose a reason for hiding this comment

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

There is one difference, though, that Categorical(..) will make a copy of the codes, while the current ensure helper does not do that.

I suppose it won't matter that much in those cases. But in general we should maybe also add a copy keyword to Categorical.

@jbrockmendel
Copy link
Member Author

But in general we should maybe also add a copy keyword to Categorical.

Good idea

@jreback jreback added the Categorical Categorical Data Type label Apr 17, 2020
@jreback jreback added this to the 1.1 milestone Apr 17, 2020
@jreback jreback merged commit c4226d4 into pandas-dev:master Apr 17, 2020
@jbrockmendel jbrockmendel deleted the ensure_cat branch April 17, 2020 02:55
CloseChoice pushed a commit to CloseChoice/pandas that referenced this pull request Apr 20, 2020
rhshadrach pushed a commit to rhshadrach/pandas that referenced this pull request May 10, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Categorical Categorical Data Type Clean
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants