我想使用
在Excel中选择特定列import pandas as pd
file = 'battledeath.xlsx'
df3 = xl.parse('2004', parse_cols=[0], skiprows=[0], names=['Country'])
# Print the head of the DataFrame df2
print(df3.head())
我试过这个并收到错误
ValueError: Length mismatch: Expected axis has 2 elements, new values have 1 elements
我在期待
Country
0 Albania
1 ......
2 ......
3 ..........
4 .....