-
-
Notifications
You must be signed in to change notification settings - Fork 18.4k
first line comments on a read_csv #4623
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
Milestone
Comments
see also #4505 |
of course in the header is special issue |
yeah, now I think about it, the first behaviour is ok. Only ignoring header is bug. |
I don't think this is an issue anymore: >>> from pandas import read_csv
>>> from pandas.compat import StringIO
>>> data = '# notes\na,b,c\n# more notes\n1,2,3'
>>> read_csv(StringIO(data), engine='c', comment='#')
a b c
0 1 2 3
>>> read_csv(StringIO(data), engine='python', comment='#')
a b c
0 1 2 3
>>> read_csv(StringIO(data), engine='c', comment='#', header=None)
0 1 2
0 a b c
1 1 2 3
>>> read_csv(StringIO(data), engine='python', comment='#', header=None)
0 1 2
0 a b c
1 1 2 3 |
ok, this looks closable, can you put some tests. |
gfyoung
added a commit
to forking-repos/pandas
that referenced
this issue
Aug 2, 2016
jreback
pushed a commit
that referenced
this issue
Aug 3, 2016
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
related #4505
It seems that commenting on the first line is a little buggy (or perhaps not well-defined):
If you ignore the header:
related #3001 and from this SO question.
The text was updated successfully, but these errors were encountered: