Skip to content

Commit ea6b448

Browse files
committed
Merge pull request #8125 from dxshank/dev-update-read-csv-docs
DOC: Link to Python standard encodings from read_csv documentation
2 parents d5c9a22 + dba1017 commit ea6b448

File tree

2 files changed

+9
-3
lines changed

2 files changed

+9
-3
lines changed

doc/source/io.rst

+6-2
Original file line numberDiff line numberDiff line change
@@ -165,7 +165,9 @@ They can take a number of arguments:
165165
- ``converters``: a dictionary of functions for converting values in certain
166166
columns, where keys are either integers or column labels
167167
- ``encoding``: a string representing the encoding to use for decoding
168-
unicode data, e.g. ``'utf-8``` or ``'latin-1'``.
168+
unicode data, e.g. ``'utf-8``` or ``'latin-1'``. `Full list of Python
169+
standard encodings
170+
<https://docs.python.org/3/library/codecs.html#standard-encodings>`_
169171
- ``verbose``: show number of NA values inserted in non-numeric columns
170172
- ``squeeze``: if True then output with only one column is turned into Series
171173
- ``error_bad_lines``: if False then any lines causing an error will be skipped :ref:`bad lines <io.bad_lines>`
@@ -372,7 +374,9 @@ result in byte strings being decoded to unicode in the result:
372374
df['word'][1]
373375
374376
Some formats which encode all characters as multiple bytes, like UTF-16, won't
375-
parse correctly at all without specifying the encoding.
377+
parse correctly at all without specifying the encoding. `Full list of Python
378+
standard encodings
379+
<https://docs.python.org/3/library/codecs.html#standard-encodings>`_
376380

377381
.. _io.index_col:
378382

pandas/io/parsers.py

+3-1
Original file line numberDiff line numberDiff line change
@@ -132,7 +132,9 @@ class ParserWarning(Warning):
132132
delimiter : string, default None
133133
Alternative argument name for sep. Regular expressions are accepted.
134134
encoding : string, default None
135-
Encoding to use for UTF when reading/writing (ex. 'utf-8')
135+
Encoding to use for UTF when reading/writing (ex. 'utf-8'). `List of Python
136+
standard encodings
137+
<https://docs.python.org/3/library/codecs.html#standard-encodings>`_
136138
squeeze : boolean, default False
137139
If the parsed data only contains one column then return a Series
138140
na_filter : boolean, default True

0 commit comments

Comments
 (0)