-
-
Notifications
You must be signed in to change notification settings - Fork 17.9k
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/ENH: groupby quantile arraylike fails with integer columns #30462
BUG/ENH: groupby quantile arraylike fails with integer columns #30462
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this is not the right solution as we are not adding a confusing at best parameter to a public function
this entire routine needs to be refactored to avoid the current method which is highly suspect now
hi Jeff, thanks for review. |
group by quantile needs the refactor to avoid the need to reindex the multiindex which is causing the issue now) you can close or push to this PR up to u |
Sorry I messed up the different commits and reverts in this branch. Will close this PR and open a new one. |
When columns are integers,
df.groupby(label).quantile(<arraylike>)
fails.This PR fixes this issue by telling
MultiIndex
to only look for positional levels during an reordering operation.Two new internal methods in
MultiIndex
class, and one new parameter forDataFrame.reorder_levels
andMultiIndex.reorder_levels
are added during the debugging process.black pandas
git diff upstream/master -u -- "*.py" | flake8 --diff