Study
Pandas · groupby
Split-apply-combine with groupby: aggregations, named agg, multiple keys, transform vs agg, and filter.
- groupby is split, then apply, then combine.
- transform returns a result the same shape as the input; agg returns one row per group.