Answers for "pandas mean and sum"

0

pandas mean and sum

d = {'Missed':'Sum1', 'Credit':'Sum2','Grade':'Average'}
df=df.groupby('Name').agg({'Missed':'sum', 'Credit':'sum','Grade':'mean'}).rename(columns=d)
Posted by: Guest on July-02-2021

Python Answers by Framework

Browse Popular Code Answers by Language