我的数据集是csv文件。 其中一些注释行带有元数据,但不一定是第一行。你知道吗
在这一点上,我用numpy.genfromtxt效果很好。 不过,我希望能够导入评论行以及扫描他们的某些准则。你知道吗
有没有简单的方法?你知道吗
例如:
''' Beginning of File '''
' comment tag ' ' Name of colums'
' comment tag '' Something i don't care about '
' comment tag '' Something i care about '
' Data '
''' End of file '''
然后我想这样做:
if ' Something i care about ' == ' criteria':
do_something
目前没有回答
相关问题 更多 >
编程相关推荐