mean in groupby different than mean in describe pandas code example Example: pandas groupby mean df.groupby(['A', 'B']).mean()