- geography
The geography of your data.
- variables
Character string or vector of character strings of variable
IDs. tidycensus automatically returns the estimate and the margin of error
associated with the variable.
- table
The ACS table for which you would like to request all
variables. Uses lookup tables to identify the variables; performs faster
when variable table already exists through load_variables(cache =
TRUE)
. Only one table may be requested per call.
- cache_table
Whether or not to cache table names for faster future
access. Defaults to FALSE; if TRUE, only needs to be called once per
dataset. If variables dataset is already cached via the
load_variables
function, this can be bypassed.
- year
The year, or endyear, of the ACS sample. 5-year ACS data is
available from 2009 through 2022; 1-year ACS data is available from 2005
through 2022, with the exception of 2020. Defaults to 2022.
- output
One of "tidy" (the default) in which each row represents an
enumeration unit-variable combination, or "wide" in which each row
represents an enumeration unit and the variables are in the columns.
- state
An optional vector of states for which you are requesting data.
State names, postal codes, and FIPS codes are accepted. Defaults to NULL.
- county
The county for which you are requesting data. County names and
FIPS codes are accepted. Must be combined with a value supplied to `state`.
Defaults to NULL.
- zcta
The zip code tabulation area(s) for which you are requesting
data. Specify a single value or a vector of values to get data for more
than one ZCTA. Numeric or character ZCTA GEOIDs are accepted. When
specifying ZCTAs, geography must be set to `"zcta"` and `state` must be specified with
`county` left as `NULL`. Defaults to NULL.
- geometry
if FALSE (the default), return a regular tibble of ACS data.
if TRUE, uses the tigris package to return an sf tibble with simple feature
geometry in the `geometry` column.
- keep_geo_vars
if TRUE, keeps all the variables from the Census
shapefile obtained by tigris. Defaults to FALSE.
- shift_geo
(deprecated) if TRUE, returns geometry with Alaska and Hawaii shifted for
thematic mapping of the entire US. Geometry was originally obtained from
the albersusa R package. As of May 2021, we recommend using tigris::shift_geometry()
instead.
- summary_var
Character string of a "summary variable" from the ACS to
be included in your output. Usually a variable (e.g. total population) that
you'll want to use as a denominator or comparison.
- key
Your Census API key. Obtain one at
https://api.census.gov/data/key_signup.html
- moe_level
The confidence level of the returned margin of error. One
of 90 (the default), 95, or 99.
- survey
The ACS contains one-year, three-year, and five-year surveys
expressed as "acs1", "acs3", and "acs5". The default selection is "acs5."
- show_call
if TRUE, display call made to Census API. This can be very
useful in debugging and determining if error messages returned are due to
tidycensus or the Census API. Copy to the API call into a browser and see
what is returned by the API directly. Defaults to FALSE.
- ...
Other keyword arguments