Description Usage Arguments See Also Examples
Separates a column containing year groups, such as "1983-1985
", into
two separate columns named year_min
and year_max
by default.
1 2 | separate_year_groups(data, year_group = year_group,
into = c("year_min", "year_max"), sep = "-")
|
data |
A data frame |
year_group |
The unquoted column containing the |
into |
The names of the min year and max year columns (respectively)
into which the minimum and maximum year from |
sep |
Characters separating years in |
Other year processors: add_mid_year_groups
,
complete_year_groups
1 2 3 4 5 | year_groups <- c("1981-1985", "1986-1990", "1991-1995", "1996-2000",
"2001-2005", "2006-2010", "2011-2015")
dplyr::tibble(year_group = year_groups) %>%
separate_year_groups()
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.