I have this DataFrame
ddd = pd.DataFrame({'day':['m','t','m','t','m','t','m','t']
,'val':[15,2,10,4,5,8,2,10]})
I want to groupby by day and aggregate the val with ewm
If I do groupby and mean I get this
ddd.groupby(['day']).mean()
val
day
m 8
t 6
Now same like this if I try
ddd.groupby(['day']).ewm(com=1.0).mean()
I get error AttributeError: 'DataFrameGroupBy' object has no attribute 'ewm'
My expected output would look like this
val
day
m 4.733333
t 8.133333