import pandas as pd
data = pd.read_excel(r'C:\Users\Administrator\AppData\Local\Programs\Python\Python37\test.xlsx')
print(data)
data = data.drop_duplicates(subset=’’, keep='first', inplace=’’)
group1 = data.groupby('x')
list(group1)
list(group1)[1]
list(group1)[0][1]

import win32com.client
xls = win32com.client.Dispatch("Excel.Application")
xls.Workbooks.Open("宏代码所在excel全路径")
xls.Application.Run("宏名称")
xls.Application.Quit()

REF:
https://www.cnblogs.com/loren880898/p/11303672.html
https://blog.csdn.net/culuo4781/article/details/107627094
https://www.cnblogs.com/www-qcdwx-com/p/10636254.html
数据分组
https://blog.csdn.net/weixin_38753213/article/details/103998246
https://www.jianshu.com/p/b50941b6d229
VBA
https://blog.csdn.net/zyq_victory/article/details/82960807
https://blog.csdn.net/pengkunstone/article/details/78647618

Last modification:August 1st, 2020 at 11:48 pm