Skip to content

DOC: .nlargest/smallest docs specify keep=False as valid parameter #18559

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

Closed
mroeschke opened this issue Nov 29, 2017 · 1 comment · Fixed by #18617
Closed

DOC: .nlargest/smallest docs specify keep=False as valid parameter #18559

mroeschke opened this issue Nov 29, 2017 · 1 comment · Fixed by #18617
Labels
Milestone

Comments

@mroeschke
Copy link
Member

For both DataFrame and Series docs:

keep : {‘first’, ‘last’, False}, default ‘first’
Where there are duplicate values: - first : take the first occurrence. - last : take the last occurrence.

In [2]: pd.Series(range(5)).nlargest(3, keep=False)

ValueError: keep must be either "first", "last"

In [3]: pd.DataFrame(range(5)).nsmallest(3,  0, keep=False)

ValueError: keep must be either "first", "last"
@jreback
Copy link
Contributor

jreback commented Nov 29, 2017

hmm, yeah that seems old.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants