-
-
Notifications
You must be signed in to change notification settings - Fork 18.4k
BUG: Fix some cases of groupby(...).transform with dropna=True #46209
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
lgtm @jbrockmendel comments? |
i think _take with |
|
Out of curiosity, I tried running the tests with
|
thanks @rhshadrach |
If you can find a way to make arg(s) unnecessary that'd be great. We clearly have a lot of methods/args that do similar things. |
@rhshadrach trying to clean out some old branches got me looking at this convert_indices=False thing again. In BM.take we do Assuming it is correct as-is, I think instead of calling ._take with convert_indices=True we could do
It's worth double-checking, but I'm pretty sure this is equivalent. It's a little more complicated, but would allow us to do non-trivial cleanup elsewhere. |
The indices, coming from ids, are guaranteed to be in the valid range ( The alternative you mentioned looks correct to me, but I haven't looked at the performance impact. |
Part of #17093
doc/source/whatsnew/vX.X.X.rst
file if fixing a bug or adding a new feature.The added xfails will pass when other parts of #45839 are merged.