Skip to content

DataFrame.to_csv bug: headers mis-aligned #143

Closed
@xdong

Description

@xdong

pandas version: 0.4.0 from pypi

The problem is that there is no header for the index column:

In [1]: import pandas

In [2]: d = pandas.DataFrame(randn(3, 2), range(3), ['a', 'b'])

In [3]: d.to_csv('tmp.csv')

In [4]: cat tmp.csv
a,b
0,-0.244543341458,-1.50542482731
1,-1.02524916375,0.279887233706
2,0.0657877607121,-0.786951623121

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions