Skip to content
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

[FEA] Add method argument to DataFrame.quantile #11572

Closed
rjzamora opened this issue Aug 19, 2022 · 1 comment · Fixed by #11957
Closed

[FEA] Add method argument to DataFrame.quantile #11572

rjzamora opened this issue Aug 19, 2022 · 1 comment · Fixed by #11957
Assignees
Labels
feature request New feature or request good first issue Good for newcomers Python Affects Python cuDF API.

Comments

@rjzamora
Copy link
Member

Is your feature request related to a problem? Please describe.
@charlesbluca and @mroeschke did some nice work recently to add muli-column support to Pandas' quantile method (pandas-dev/pandas#44301). The accepted solution there was to add a method argument (with the options being "table" and "single") to DataFrame.quantile, rather than adding a DataFrame.quantiles method (like we have in cudf).

The new quantile change will be introduced to Pandas in the next release. In order to simplify the development of library-agnostic multi-column sorting in dask.dataframe, I suggest that we align the cudf and pandas quantile arguments.

Describe the solution you'd like
I would like for cudf.DataFrame.quantile to have the same method argument as pd.DataFrame.quantile. In the future, it will probably make sense to deprecate cudf.DataFrame.quantiles (note the plurality) altogether.

Describe alternatives you've considered
The alternative is to allow unnecessary API divergence between cudf and pandas, complicating both dask.dataframe and user code.

@rjzamora rjzamora added feature request New feature or request Needs Triage Need team to review and classify good first issue Good for newcomers Python Affects Python cuDF API. labels Aug 19, 2022
@vyasr
Copy link
Contributor

vyasr commented Oct 18, 2022

Would love to see this make it in, quantile vs quantiles gives me a headache every time I see it in cudf.

@rjzamora rjzamora self-assigned this Oct 20, 2022
@GregoryKimball GregoryKimball removed the Needs Triage Need team to review and classify label Oct 21, 2022
rapids-bot bot pushed a commit that referenced this issue Oct 28, 2022
Adds a `method` argument to `Dataframe.quantile` to match pandas behavior. Also deprecates `DataFrame.quantiles` (with a `FutureWarning` informing the user of the `method` argument).

Closes #11572

Authors:
  - Richard (Rick) Zamora (https://github.com/rjzamora)
  - Bradley Dice (https://github.com/bdice)

Approvers:
  - Ashwin Srinath (https://github.com/shwina)
  - Bradley Dice (https://github.com/bdice)
  - Matthew Roeschke (https://github.com/mroeschke)
  - Lawrence Mitchell (https://github.com/wence-)

URL: #11957
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature request New feature or request good first issue Good for newcomers Python Affects Python cuDF API.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants