# Grouped data.frames:
mtcars %>% group_by(cyl, am) %>% group_split()
mtcars %>% group_by(cyl, am) %>% group_split(.keep = FALSE)
mtcars %>% group_by(cyl, am) %>% group_keys()
# Ungrouped data.frames:
mtcars %>% group_split(am, cyl)
Run the code above in your browser using DataLab