View source: R/get_vintage_data.R
| get_vintage_data | R Documentation | 
Function produces a data.table/dataframe of Census Bureau data. The function requires an access key issued from the Bureau.
get_vintage_data(
  dataset,
  vintage = NULL,
  vars,
  vars_init = c("GEO_ID", "NAME"),
  group = NULL,
  group_values = c("estimate", "moe"),
  region = NULL,
  regionin = NULL,
  na_cols = NULL,
  shape = "long",
  melt_meas = NULL,
  melt_values = NULL,
  key = Sys.getenv("CENSUS_KEY")
)
dataset | 
 A string that sets the name of the data set of interest (e.g. "acs/acs5")  | 
vintage | 
 An optional numeric that sets the vintage of interest.  | 
vars | 
 Can be either a string vector of variable names to be acquired. Also can be a named list of string vectors to separate groups of variables.  | 
vars_init | 
 A string vector of variable names to append to   | 
group | 
 A string that names the group that has a collection of variables. A dataframe is returned in the "long" format with a factor column named "variables" with their respective values.  | 
group_values | 
 A string vector that sets the type of output values.
Permissible values are "estimate" (for estimates) "moe" (for margin of error).
The default is   | 
region | 
 A string that specifies the geography of the request.
See   | 
regionin | 
 A string that sets a qualifier for   | 
na_cols | 
 If TRUE will remove all rows with missing values. If a vector of column names/integers will check their values for missing values.  | 
shape | 
 A string that sets the shape of the returned dataframe. Permissible values are "long" (the default) or "wide".  | 
melt_meas | 
 A   | 
melt_values | 
 A Vector that assigns a value to each of the consolidated columns.  | 
key | 
 A key string issued by the Census Bureau in making data requests.  | 
Get Census Bureau data for a specific dataset, variables, and region in the form of a dataframe.
A data.table
Rick Dean
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.