-
-
Notifications
You must be signed in to change notification settings - Fork 18.4k
FIX raise when groupby selecting cols not in frame #6578
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
rebase on master .....setuptools had changed so build was failing the 2.6 failure is real though... |
lol to the failure, similar to me just claiming was an issue in 2.6. Silly. |
not self.as_index): | ||
if isinstance(key, (list, tuple, Series, np.ndarray)): | ||
if len(self.obj.columns.intersection(key)) != len(key): | ||
bad_keys = list(set(key).difference(self.obj.columns)) |
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.
@jreback Thinking about this, do you know if there is a helper function in loc already that might be better than this hack?
maybe slightly more intuitive, but yours pretty self exaplanatory
|
subtle improveent is that yours doesn't allow for repeats... whhich is not supported... should it be :s (rabbit hole?) |
hmm I suppose that should technically be allowed |
No methods work at the moment (as you're reindexing by a dupe), will have a little think. |
the reindexing could be fixed, but i think you are right, it opens a big can of worms.So pls add a check and test for dups (just raise ValueError) for now. |
Now I think about it, not tested axis=1...at all (I'm guessing this won't work, I could just raise as NotImplemented ) :S |
more tests on this for axis=1? release notes? |
ping! |
ping |
@hayd ping....need to get this in ASAP |
this looks fine. anything else on this? give ok and I'll merge it (I want to update the release note a bit) |
Will have some time for this late tomorrow (and wed and thurs), sorry been swamped recently, need to pull finger out on many PRs lined up mañana. I see point on axis=1, I'm worried machinery is different... and not played with this. |
ping! |
FIX raise when groupby selecting cols not in frame
KeyError part of #5264