Closed jhofman closed 2 years ago
@chisingh Here is an example spec grouping the penguin data by three grouping variables and getting the mean bill_length_mm.
It uses the palmerpenguins dataset, looks like there's also a python version of the package! The datamations package itself doesn't contain the penguins data set, but rather shows loading palmerpenguins
and using the data from there, so might be good to try out using an external data set in the python version too.
R code for the operation:
library(palmerpenguins)
library(dplyr)
penguins %>%
group_by(species, island, sex) %>%
summarize(mean = mean(bill_length_mm))
Just a thought for testing, it would be good to generate the groups in a different order (e.g. species, island, sex vs island, sex, species) and also test generating the mean of different columns (there's bill length, bill depth, etc).
Closed by #162
@chisingh will work on a three-variable grouping example.
@sharlagelfand, can you add the spec from the shiny app example here?