Skip to content

Instantly share code, notes, and snippets.

@AayushSameerShah
Created June 9, 2021 14:49
Show Gist options
  • Save AayushSameerShah/fcf7b4f3b7e00305ba5797b836a49183 to your computer and use it in GitHub Desktop.
Save AayushSameerShah/fcf7b4f3b7e00305ba5797b836a49183 to your computer and use it in GitHub Desktop.
Here, the simplest form of groupping by rows is present
# Simple and easy
df.gropby(df.index // n_rows).mean()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment