Skip to content

DOC: Typo in docs for na_values parameter in pandas.read_csv function #59314

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
1 task done
rxu17 opened this issue Jul 25, 2024 · 1 comment · Fixed by #59318
Closed
1 task done

DOC: Typo in docs for na_values parameter in pandas.read_csv function #59314

rxu17 opened this issue Jul 25, 2024 · 1 comment · Fixed by #59318
Assignees
Labels
Docs Needs Triage Issue that has not been reviewed by a pandas team member

Comments

@rxu17
Copy link

rxu17 commented Jul 25, 2024

Pandas version checks

  • I have checked that the issue still exists on the latest versions of the docs on main here

Location of the documentation

https://pandas.pydata.org/docs/reference/api/pandas.read_csv.html

Documentation problem

Hi,
I was looking through the pandas documentation for the na_values parameter under pandas.read_csv and I noticed that there's a typo in the section:

By default the following values are interpreted as NaN: “ “, “#N/A”, “#N/A N/A”, “#NA”, “-1.#IND”, “-1.#QNAN”, “-NaN”, “-nan”, “1.#IND”, “1.#QNAN”, “”, “N/A”, “NA”, “NULL”, “NaN”, “None”, “n/a”, “nan”, “null “.

The " " is included in the list of default string to NAs starting in pandas 2.1 all the way to the current version of the docs. However, in the code for the list of default string to NAs, I'm seeing "" instead.

Suggested fix for documentation

I think the fix should be to remove " " and replace with "" in the list of default string to NAs in the pandas docs for the versions 2.1 and up to the current version so it's consistent with the code.

Thanks for all your help!

@rxu17 rxu17 added Docs Needs Triage Issue that has not been reviewed by a pandas team member labels Jul 25, 2024
@kushagr96
Copy link
Contributor

take

mroeschke pushed a commit that referenced this issue Aug 2, 2024
…#59314  (#59318)

* fixed formatting of default na values

* bug fix

* fixing docstring formatting

* fixing formatting for quoting
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Docs Needs Triage Issue that has not been reviewed by a pandas team member
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants