Pandas groupby is a powerful function that groups distinct sets within selected columns and aggregates metrics from other columns accordingly. Performing these operations results in a pivot table, something that’s very useful in data analysis. Aggregating Multiple Columns In this article, I share a technique for computing ad-hoc aggregations that can involve multiple…