I have a df having more than 100 columns and i want to use groupby and take mean of column having 'WR' in it and 'sum' if not using agg().
df.groupby([c1,c2]).agg({ {i for i in df.columns if 'WR' in i}:'mean', {i for i in df.columns if 'WR'
not in i}:'sum'})
Is it Possible?