diff --git a/doc/source/io.rst b/doc/source/io.rst index dd1cde0bdff73..873c528b11f09 100644 --- a/doc/source/io.rst +++ b/doc/source/io.rst @@ -1672,7 +1672,8 @@ function takes a number of arguments. Only the first is required. * ``mode`` : Python write mode, default 'w' * ``encoding``: a string representing the encoding to use if the contents are non-ASCII, for Python versions prior to 3 -* ``line_terminator``: Character sequence denoting line end (default '\\n') +* ``line_terminator``: Character sequence denoting line end. By default + this is platform specific (default ``os.linesep``) * ``quoting``: Set quoting rules as in csv module (default csv.QUOTE_MINIMAL). Note that if you have set a `float_format` then floats are converted to strings and csv.QUOTE_NONNUMERIC will treat them as non-numeric * ``quotechar``: Character used to quote fields (default '"') * ``doublequote``: Control quoting of ``quotechar`` in fields (default True) diff --git a/pandas/io/formats/csvs.py b/pandas/io/formats/csvs.py index 46c843af043e7..5ca47f51ede95 100644 --- a/pandas/io/formats/csvs.py +++ b/pandas/io/formats/csvs.py @@ -30,7 +30,7 @@ class CSVFormatter(object): def __init__(self, obj, path_or_buf=None, sep=",", na_rep='', float_format=None, cols=None, header=True, index=True, index_label=None, mode='w', nanRep=None, encoding=None, - compression='infer', quoting=None, line_terminator='\n', + compression='infer', quoting=None, line_terminator=None, chunksize=None, tupleize_cols=False, quotechar='"', date_format=None, doublequote=True, escapechar=None, decimal='.'):