-
Notifications
You must be signed in to change notification settings - Fork 98
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
Add mode to dataframe and series #323
Conversation
Since this is a community submitted pull request, a Jenkins build has not been kicked off automatically. Can an Elastic organization member please verify the contents of this patch and then kick off a build manually? |
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 really great, here are some comments for you!
@sethmlarson If you're happy with the change, I will rebase my branch and resolve merge conflicts :) |
jenkins test this please |
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.
Sorry for letting this go so long without a final review, I'm pretty sure this is ready but want to run it against the new pandas v1.2.0, can you rebase?
I forgot to include |
@sethmlarson Ask jenkins to test this. |
jenkins test this please |
CI is good 🔥 |
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 almost done! Here's a couple more comments:
I had to make one small change to tests because
|
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.
Just one more comment, otherwise looks good to me!
jenkins test this please |
Added those files. |
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, thank you!
Closes #215
Added mode to dataframe and series
Added tests, documentation
Currently mode isn't supported by
pandas groupby
too, Hence added aNotImplementedError
To satisfy
mypy
I had to add type hints to some other methods too.Implemented es_size parameter instead of dumping the entire cluster if we have multiple mode values.
Currently dropna=True is only supported because I have a query on
missing
parameter of terms aggregationReference
@sethmlarson Please review 😃