-
-
Notifications
You must be signed in to change notification settings - Fork 18.5k
BUG: union_categoricals w/Series & CategoricalIndex #14173
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
Comments
xref to #13767 though this is independent |
further I think we need a doc-note at the end of the unionining section in categorical.rst. Showing that when unioned categoricals are re-coded. Even though this is technically a dtype implementation detail that the categoricals hide, unioning re-codes, so the user should be aware.
note that some users, @mrocklin (dask), actually like/want this! |
Yep, I agree that |
How should the index be handled in the In [1]: pd.concat([pd.Series([1,2,3]), pd.Series([3,4,5])])
Out[1]:
0 1
1 2
2 3
0 3
1 4
2 5
dtype: int64
In [2]: pd.concat([pd.Series([1,2,3]), pd.Series([3,4,5])], ignore_index=True)
Out[2]:
0 1
1 2
2 3
3 3
4 4
5 5
dtype: int64 |
I would do it similar as |
I disagree, I think this should always return a Until we add this functionaility to |
Oh, you wouldn't even box it back in the original type? I guess that makes sense as that usecase should really be handled by |
I don't see why this shouldn't work. This should return a Categorical.
actual categoricals are combinable
This works fine
But this is broken
The text was updated successfully, but these errors were encountered: