基于pandas

import pandas as pd 

#read xlsx file
df = pd.read_excel('test.xlsx')
#read sheet in xlsx file
df = pd.read_excel('test.xlsx', sheet_name='Sheet1')
print(df)
print(df.describe()) 

#col title
print(df.columns)
print(df['col_name'])

#
for index_data in df.index:
    print(df.loc[index_data].values)
Last modification:February 14th, 2022 at 09:37 am