sepstr, default ‘,’
Delimiter to use. If sep is None, the C engine cannot automatically detect the separator, but the Python parsing engine can, meaning the latter will be used and automatically detect the separator by Python’s builtin sniffer tool, csv.Sniffer. In addition, separators longer than 1 character and different from '\s+' will be interpreted as regular expressions and will also force the use of the Python parsing engine. Note that regex delimiters are prone to ignoring quoted data. Regex example: '\r\t'.
delimiterstr, default None
Alias for sep.
看了文献没有看懂。。。。。请指导
是不是sep,delimiter只能设置一个,优先使用sep作为分隔符,如果sep没有设置的话,则以delimiter作为分隔符?
看下源码呗,源码写的很清楚,这里是链接,能回答你的所有疑惑。
但还是给个建议,优先用
sep
,因为它短(其实是因为一些其他方法中只能用sep
,就记这一个就行了)。