-
-
Notifications
You must be signed in to change notification settings - Fork 18.5k
DOC: Improve to_csv mode documentation #51839
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
Comments
@datapythonista - Thanks for the help on this one! |
Thanks for reporting. When only a subset of the values is expected, instead of using the type To explain the types, we can also use bullet points, we do that in some docs, may make things easier to read. It'd be good to see which other |
One important value is also |
take |
@datapythonista - strongly agree with this, especially because the different I don't mean to overcomplicate this too much, but for I mention this because the |
I agree that it would be helpful to have the available modes for to_csv() explicitly listed in the documentation. Thanks for suggesting this improvement! |
From a quick look I can only see |
Modify write mode descriptions and add an explanation for b and t mode.
Put path_or_buf in backticks.
Remove the 'b' and 't' modes from the description.
Modify 'w', 'a', and 'x' write mode's description.
* DOC update DataFrame.to_csv write modes (#51839) * DOC: style fix (#51839) * DOC update DataFrame.to_csv write modes (#51839) Modify write mode descriptions and add an explanation for b and t mode. * DOC: update DataFrame.to_csv write modes (#51839) Put path_or_buf in backticks. * DOC: update DataFrame.to_csv write modes (#51839) Remove the 'b' and 't' modes from the description. * DOC: update DataFrame.to_csv write modes (#51839) Modify 'w', 'a', and 'x' write mode's description.
Pandas version checks
main
hereLocation of the documentation
https://pandas.pydata.org/docs/reference/api/pandas.DataFrame.to_csv.html
Documentation problem
The
to_csv
mode method does not explicitly list the options for users. It links to the Pythonopen()
method that contains some options that aren't relevant.Suggested fix for documentation
It'd be nice to list the mode options right in the
to_csv
docs. This should be significantly more user-friendly. Suggested text:The text was updated successfully, but these errors were encountered: