Skip to content

DOC: improve description of the example which dataframe has two rows #36971

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

Merged
merged 5 commits into from
Oct 11, 2020

Conversation

yonashub
Copy link
Contributor

@yonashub yonashub commented Oct 8, 2020

improve description of the example which dataframe has two rows

improve description of the examplewhich dataframe has two rows
Copy link
Member

@MarcoGorelli MarcoGorelli left a comment

Choose a reason for hiding this comment

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

Nice, I agree that this is clearer, am just leaving a suggestion

@@ -8972,7 +8972,7 @@ def mode(self, axis=0, numeric_only=False, dropna=True) -> DataFrame:

By default, missing values are not considered, and the mode of wings
are both 0 and 2. The second row of species and legs contains ``NaN``,
because they have only one mode, but the DataFrame has two rows.
because they have only one mode, but the resulting DataFrame has two rows.
Copy link
Member

Choose a reason for hiding this comment

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

How about

Because the resulting DataFrame has two rows, the second row of ``species`` and ``legs`` contains ``NaN``

? (you may need to wrap this around multiple lines)

Copy link
Contributor Author

Choose a reason for hiding this comment

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

That is more descriptive. Totally agreed

Copy link
Member

Choose a reason for hiding this comment

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

Cool - could you also put a more descriptive title for your pull request please?

@jreback jreback changed the title fix issue 36970 DOC: improve description of the examplewhich dataframe has two rows Oct 8, 2020
@jreback jreback added the Docs label Oct 8, 2020
improve description of the example which dataframe has two rows
@pep8speaks
Copy link

pep8speaks commented Oct 9, 2020

Hello @yonashub! Thanks for updating this PR. We checked the lines you've touched for PEP 8 issues, and found:

There are currently no PEP 8 issues detected in this Pull Request. Cheers! 🍻

Comment last updated at 2020-10-11 18:32:15 UTC

@yonashub yonashub changed the title DOC: improve description of the examplewhich dataframe has two rows DOC: improve description of the example which dataframe has two rows Oct 9, 2020
@MarcoGorelli MarcoGorelli added this to the 1.2 milestone Oct 11, 2020
@MarcoGorelli MarcoGorelli merged commit 37b3774 into pandas-dev:master Oct 11, 2020
@MarcoGorelli
Copy link
Member

Thanks @yonashub

In the future, it would be better to create a new branch when submitting PRs, see the contributing guide

JulianWgs pushed a commit to JulianWgs/pandas that referenced this pull request Oct 26, 2020
…andas-dev#36971)

* fix issue 36970

improve description of the examplewhich dataframe has two rows

* improve description of example

improve description of the example which dataframe has two rows

* improve description of the example describing mode operation.

* remove trailing extra line

* preserve newline

Co-authored-by: yonas kassa <[email protected]>
Co-authored-by: Marco Gorelli <[email protected]>
kesmit13 pushed a commit to kesmit13/pandas that referenced this pull request Nov 2, 2020
…andas-dev#36971)

* fix issue 36970

improve description of the examplewhich dataframe has two rows

* improve description of example

improve description of the example which dataframe has two rows

* improve description of the example describing mode operation.

* remove trailing extra line

* preserve newline

Co-authored-by: yonas kassa <[email protected]>
Co-authored-by: Marco Gorelli <[email protected]>
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 this pull request may close these issues.

DOC: improve description of the examplewhich dataframe has two rows
4 participants