-
-
Notifications
You must be signed in to change notification settings - Fork 18.5k
BUG: Use self._constructor_sliced in df._reduce to respect subclassed… #30945
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
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.
Thanks @EmilianoJordan for the PR. will need whatsnew once #30907 is merged.
Subscribed to #30907 to know when I can do this. Also, updated the initial pull request comment to reflect that this has not been completed. |
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.
lgtm. pls add a whatsnew note for 1.1, you can put in the bug fix section for reshaping.
Add whatsnew/v1.1.0rst
doc/source/whatsnew/v1.1.0.rst
Outdated
@@ -140,7 +140,7 @@ Groupby/resample/rolling | |||
Reshaping | |||
^^^^^^^^^ | |||
|
|||
- | |||
- Bug in :meth:`DataFrame._reduce` not returning subclassed data type effecting all numeric and boolean reduction methods. (:issue:`25596`) |
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 a public method, can you update with something a user would want to know, e.g. DataFrame.sum()
etc.
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.
List all 12 methods then?
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.
I'm working on a more comprehensive review of subclassing. How about I just add that to this PR and list all the methods? It'll be ~20 methods, but it'll get it all out of the way in one go.
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.
u can list if u want or just sat reduction methods
thanks @EmilianoJordan |
… types. (GH25596)
black pandas
git diff upstream/master -u -- "*.py" | flake8 --diff