Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

get_tract_demographics

Get a handful of demographic variables on Census Tracts in a State from the US Census Bureau as a data.frame.


Description

The data comes from the American Community Survey (ACS). The variables are: total population, percent White not Hispanic, Percent Black or African American not Hispanic, percent Asian not Hispanic, percent Hispanic all races, per-capita income, median rent and median age.

Usage

get_tract_demographics(
  state_name,
  county_fips = NULL,
  endyear = 2013,
  span = 5
)

Arguments

state_name

The name of the state. See ?state.regions for proper spelling and capitalization.

county_fips

An optional vector of county fips codes within the state. Useful to set because getting data on all tracts can be slow.

endyear

The end year for the survey

span

The span of the survey

References

The choroplethr guide to Census data: http://www.arilamstein.com/open-source/choroplethr/mapping-us-census-data/

A list of all ACS Surveys: http://factfinder.census.gov/faces/affhelp/jsf/pages/metadata.xhtml?lang=en&type=survey&id=survey.en.ACS_ACS


choroplethr

Simplify the Creation of Choropleth Maps in R

v3.7.0
BSD_3_clause + file LICENSE
Authors
Ari Lamstein [aut, cre], Brian Johnson [ctb], Trulia, Inc. [cph]
Initial release

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.