📜  导入excel python代码示例

📅  最后修改于: 2022-03-11 14:45:56.155000             🧑  作者: Mango

代码示例4
#Creating the ExcelFile object
xls = pd.ExcelFile(r'Path.xlsx')
#In the next step, you can pass the ExcelFile object to read_excel to import
#its content, instead of the path to the file.
data = pd.read_excel(xls,  sheet_name='Name_of_sheet', index_col='Index_Column')