哈喽,艾瑞巴蒂。这里我用到的是jupyter notebook.用到的库有pandas,numpy 等。
方法一: sheet_name =0 (0-代表索引,默认列表名的索引从0开始)
方法二: sheet_name ='字符串’(字符串—字表名)
pd.read_excel(‘F:\desktop\六月数据详情.xlsm’, sheet_name =0)
pd.read_excel(‘F:\desktop\六月数据详情.xlsm’, sheet_name =‘Sheet1’)
如图:注意方法二区分大小写和空格
pd.read_excel('F:\desktop\六月数据详情.xlsm', usecols=[0,8])
str-list:['列名’,‘列名’]
例如:
pd.read_excel('F:\desktop\六月数据详情.xlsm', usecols=['日期','总收入'])
本文地址:https://blog.csdn.net/xiaoyun5555/article/details/107311974
如对本文有疑问, 点击进行留言回复!!
python+selenium自动化(七)__键盘、鼠标操作及下拉框
File “<frozen importlib._bootstrap>“, line 219, in _call_with_frames_removed ValueError: source cod
网友评论