Post

Using "resample" groups a #Python #Pandas data frame with a datetime index with arbitrary time units, similar to Grouper. For example, mean total_amount every 8-hours: df.resample('8h')['total_amount'].mean() Or tip_amount per day: df.resample('1D')['tip_amount'].mean()

1 repost3 likes

No replies yet.