R/search_variables.R
load_variables.Rd
Load variables from a decennial Census or American Community Survey dataset to search in R
load_variables(
year,
dataset = c("sf1", "sf2", "sf3", "sf4", "pl", "dhc", "dp", "as", "gu", "mp", "vi",
"acsse", "dpas", "dpgu", "dpmp", "dpvi", "acs1", "acs3", "acs5", "acs1/profile",
"acs3/profile", "acs5/profile", "acs1/subject", "acs3/subject", "acs5/subject",
"acs1/cprofile", "acs5/cprofile"),
cache = FALSE
)
The year for which you are requesting variables. Either the year or endyear of the decennial Census or ACS sample. 5-year ACS data is available from 2009 through 2020. 1-year ACS data is available from 2005 through 2021, with the exception of 2020.
One of "sf1", "sf2", "sf3", "sf4", "pl", "dhc", "dp", "as", "gu", "mp", "vi", "acsse", "acs1", "acs3", "acs5", "acs1/profile", "acs3/profile", "acs5/profile", "acs1/subject", "acs3/subject", "acs5/subject", "acs1/cprofile", or "acs5/cprofile".
Whether you would like to cache the dataset for future access, or load the dataset from an existing cache. Defaults to FALSE.
A tibble of variables from the requested dataset.
if (FALSE) {
v15 <- load_variables(2015, "acs5", cache = TRUE)
View(v15)
}