python读取不同格式的文件
采用python语言读取不同格式数据表文件,其中包括路径,文件后缀等。第一步:先导入数据,如Excel-数据-导入student1.csv;student1.tsv[allfiles存储];student1.txt);第二步:采用Python导入,如
importpandasaspd
student2=pd.read_csv('d:\ProgramFiles\python3x\Temp\student1.txt',sep='|',index_col='ID')
print(student2)
下载地址
用户评论