clean_age_population_year: Prepare age population data

View source: R/utils.R

clean_age_population_yearR Documentation

Prepare age population data

Description

Internally used function within age_population() to separate age groups into its lower & upper limit and then filter the data passed to the desired year and location.

Usage

clean_age_population_year(
  data,
  location_col = NULL,
  location = NULL,
  age_col,
  year_col = NULL,
  year = NULL
)

Arguments

data

data.frame

location_col

bare unquoted variable referring to location column

location

location name to filter to. If not specified gives all locations.

age_col

bare unquoted variable referring to age column

year_col

bare unquoted variable referring to year column

year

year to filter to. If not specified, gives all years.

Value

data frame with lower.age.limit and upper.age.limit and optionally filtered down to specific location or year.


njtierney/conmat documentation built on April 17, 2025, 10:27 p.m.