- 一、读取excel数据生成Dataframe
- 二、Dataframe中获取想要的行列数据
- 三、字段重新命名
- 四、添加新的字段,调整字段顺序
- 五、为df添加统计行
- 六、把df中数据保存到excel中
一、读取excel数据生成Dataframe
读取excel,表的字段名称在第4行
import pandas as pd #读取excel,列字段在第4行 df = pd.read_excel(r"/User

读取excel,表的字段名称在第4行
import pandas as pd #读取excel,列字段在第4行 df = pd.read_excel(r"/User