Skip to content

make GroupKey API more consistent#2308

Merged
bkamins merged 4 commits intoJuliaData:masterfrom
bkamins:more_groupkey_functions
Aug 2, 2020
Merged

make GroupKey API more consistent#2308
bkamins merged 4 commits intoJuliaData:masterfrom
bkamins:more_groupkey_functions

Conversation

@bkamins
Copy link
Copy Markdown
Member

@bkamins bkamins commented Jun 29, 2020

Add missing methods for GroupKey to make it consistent with DataFrameRow which is similar.

See #2305 for discussion. CC @goretkin.

Also this should be made consistent with #2281 whichever gets merged first. CC @pdeffebach

After this PR and #2281 another one with ==, isequal, in etc. definitions should be done.

I hope I have not missed any definitions - could you please check? Thank you!

@bkamins bkamins changed the title make GroupKey API more consistent [BREAKING] make GroupKey API more consistent Jun 29, 2020
@bkamins bkamins added breaking The proposed change is breaking. grouping labels Jun 29, 2020
@bkamins bkamins added this to the 1.0 milestone Jun 29, 2020
Instances of this type are returned by `keys(::GroupedDataFrame)` and are not
meant to be constructed directly.

Indexing is one-dimensional like specifying a column of a `DataFrame`.
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

I don't understand the "like" part.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

I have copied it from DataFrameRow docstring, so we should fix it also there. It is meant that the rules are the same as for the second dimension in data frame. How do you think we could phrase it?

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

OK. Maybe something about accepted index types?

@bkamins
Copy link
Copy Markdown
Member Author

bkamins commented Jul 29, 2020

@nalimilan - I have updated the docstring

@bkamins
Copy link
Copy Markdown
Member Author

bkamins commented Jul 30, 2020

Only coverage fails

Copy link
Copy Markdown
Member

@nalimilan nalimilan left a comment

Choose a reason for hiding this comment

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

Just a small suggestion.

Co-authored-by: Milan Bouchet-Valat <nalimilan@club.fr>
@bkamins bkamins merged commit 945b777 into JuliaData:master Aug 2, 2020
@bkamins bkamins deleted the more_groupkey_functions branch August 2, 2020 07:39
@bkamins
Copy link
Copy Markdown
Member Author

bkamins commented Aug 2, 2020

Thank you!

@bkamins bkamins changed the title [BREAKING] make GroupKey API more consistent make GroupKey API more consistent Aug 7, 2020
@bkamins bkamins removed the breaking The proposed change is breaking. label Aug 7, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants