st_combine por variables r
states %>%
group_by(group_var) %>%
summarize(geometry = st_union(geometry))
marcofaga
states %>%
group_by(group_var) %>%
summarize(geometry = st_union(geometry))