Skip to content

BUG: Fix qcut for nullable integers #31440

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 21 commits into from
Feb 2, 2020
Merged

BUG: Fix qcut for nullable integers #31440

merged 21 commits into from
Feb 2, 2020

Conversation

dsaxton
Copy link
Member

@dsaxton dsaxton commented Jan 30, 2020

  • tests added / passed
  • passes black pandas
  • whatsnew entry

Related to #31389 but doesn't close any issues that I'm aware of. Seems the problems were indexing into a numpy array with a BooleanArray and using searchsorted in the presence of pd.NA.

-
-

- Bug where :meth:`qcut` would raise when passed a nullable integer. (:issue:`31389`)
Copy link
Member

Choose a reason for hiding this comment

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

I think this can go in the 1.0.1 whatsnew now that it's been created.

@jschendel jschendel added Bug Reshaping Concat, Merge/Join, Stack/Unstack, Explode labels Jan 31, 2020
@jschendel jschendel added this to the 1.0.1 milestone Jan 31, 2020
Daniel Saxton added 6 commits January 31, 2020 08:34
Copy link
Contributor

@jreback jreback left a comment

Choose a reason for hiding this comment

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

ping on green.

@jreback
Copy link
Contributor

jreback commented Feb 1, 2020

pls merge master as well

Copy link
Contributor

@jreback jreback left a comment

Choose a reason for hiding this comment

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

lgtm. can you move the comments, ping on green.

@@ -203,16 +203,13 @@ def cut(
# NOTE: this binning code is changed a bit from histogram for var(x) == 0

# for handling the cut for datetime and timedelta objects
Copy link
Contributor

Choose a reason for hiding this comment

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

ok, can you move all of these comments inside _coerce_to_type

@jreback
Copy link
Contributor

jreback commented Feb 2, 2020

great long on green

@dsaxton
Copy link
Member Author

dsaxton commented Feb 2, 2020

@jreback All green, thanks for the review

@jreback jreback merged commit 83f84ed into pandas-dev:master Feb 2, 2020
@jreback
Copy link
Contributor

jreback commented Feb 2, 2020

thanks @dsaxton

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Reshaping Concat, Merge/Join, Stack/Unstack, Explode
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants