I have got the following pandas DataFrame:
time, value
2018-08-02 09:19:37, 2
2018-08-02 09:19:47, 3
2018-08-02 09:19:57, 6
......
2018-08-03 04:49:27, 2
2018-08-03 04:49:37, 4
2018-08-03 04:49:47, 5
I would like to build an output dataFrame as in the following:
time, value
2018-08-02 11:59:59, AVG(2+3+6+..)
2018-08-03 11:59:59, AVG(2+4+5+..)
Please any help would very appreciated. Many Thanks.
df.groupby(df.time.dt.date).value.mean()
?? – Cardiovasculardf.value=df.value.astype(int)
and then try, check my answer for detailed explaination – Cardiovascular