CommencerCommencer gratuitement

Groupby

Groupbys are an incredibly powerful and fast way to perform calculations, transformations, and filter your data. It follows the mantra of split-apply-combine where the dataset is split into multiple partitions based on unique values of a variable or variables, a function is applied on each partition separately, and all the results are combined together at the end.

Cet exercice fait partie du cours

Python for R Users

Afficher le cours

Exercice interactif pratique

Essayez cet exercice en complétant cet exemple de code.

# Mean tip by sex
print(tips____(____)[____].____)
Modifier et exécuter le code