Question 40 of 93 · Window Functions
HelpRank within a group
Add a "weight_rank_in_species" column ranking each pet's weight within its own species (1 = heaviest), without collapsing any rows. Use `.rank(True).over("species")`.
Question 40 of 93 · Window Functions
HelpAdd a "weight_rank_in_species" column ranking each pet's weight within its own species (1 = heaviest), without collapsing any rows. Use `.rank(True).over("species")`.