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

BUG: Fixed merge on dtype equal categories #19553

Merged
merged 4 commits into from
Feb 8, 2018

Conversation

TomAugspurger
Copy link
Contributor

closes #19551

@TomAugspurger TomAugspurger added the Categorical Categorical Data Type label Feb 6, 2018
@TomAugspurger TomAugspurger added this to the 0.23.0 milestone Feb 6, 2018
@codecov
Copy link

codecov bot commented Feb 6, 2018

Codecov Report

Merging #19553 into master will increase coverage by 0.01%.
The diff coverage is 88.88%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master   #19553      +/-   ##
==========================================
+ Coverage    91.6%   91.62%   +0.01%     
==========================================
  Files         150      150              
  Lines       48750    48780      +30     
==========================================
+ Hits        44657    44694      +37     
+ Misses       4093     4086       -7
Flag Coverage Δ
#multiple 89.99% <88.88%> (+0.02%) ⬆️
#single 41.73% <11.11%> (-0.02%) ⬇️
Impacted Files Coverage Δ
pandas/core/reshape/merge.py 94.25% <100%> (+0.03%) ⬆️
pandas/core/indexes/category.py 97.26% <75%> (-0.26%) ⬇️
pandas/core/apply.py 96.77% <0%> (-2.66%) ⬇️
pandas/core/indexes/datetimelike.py 97.05% <0%> (-0.05%) ⬇️
pandas/core/sparse/frame.py 94.81% <0%> (-0.04%) ⬇️
pandas/core/indexes/base.py 96.43% <0%> (-0.02%) ⬇️
pandas/core/frame.py 97.42% <0%> (-0.01%) ⬇️
pandas/core/ops.py 95.22% <0%> (ø) ⬆️
pandas/io/formats/style.py 96.22% <0%> (ø) ⬆️
pandas/core/base.py 96.78% <0%> (+0.01%) ⬆️
... and 3 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 93c86aa...9eb7f28. Read the comment docs.

@@ -679,6 +679,9 @@ Categorical
- Bug in :func:`pandas.api.types.union_categoricals` returning the wrong result
when all the categoricals had the same categories, but in a different order.
This affected :func:`pandas.concat` with Categorical data (:issue:`19096`).
- Bug in :func:`pandas.merge` when joining on a ``Categorical`` column where
the categories were unordered and had the same values but in a different
Copy link
Contributor

Choose a reason for hiding this comment

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

looks fine

maybe should elevate to a subsection to highlite this

@TomAugspurger
Copy link
Contributor Author

Found one more case hit by this (get_indexer). Made a warning in the docs, still under the bugfix section though.

@jreback jreback merged commit b2940a0 into pandas-dev:master Feb 8, 2018
@jreback
Copy link
Contributor

jreback commented Feb 8, 2018

thanks! looks good @TomAugspurger, yeah way you did docs is good.

@jreback jreback added Bug Reshaping Concat, Merge/Join, Stack/Unstack, Explode labels Feb 8, 2018
harisbal pushed a commit to harisbal/pandas that referenced this pull request Feb 28, 2018
@TomAugspurger TomAugspurger deleted the merge-dtype-equal branch May 2, 2018 13:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Categorical Categorical Data Type Reshaping Concat, Merge/Join, Stack/Unstack, Explode
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Merge on categorical type columns gives wrong results
3 participants