I am using the following code to groupby and count/sum etc.
groups = df[df['isTrade'] == 1].groupby('dateTime')
grouped = (groups.agg({'tradeBid': [np.sum,lambda x: (x > 0).sum()],}))
The output is giving me:
tradeBid tradeBid
sum <lambda>
79 46
7 6
4 4
20 6
How can I change the output's header ( so my end user will know what is this data?