Choroplethr Documentation

While Choroplethr is conceptually one body work, the Central R Archive Network (CRAN) has required me to split the project into five separate R packages.

Below is a list of a each package, along with a brief description of what it does and how to install it.

Additionally, each package has a separate page that lists all of its functions and data objects, along with examples of their use.


Choroplethr is the main package in the project. It contains an R6 object for creating choropleth maps from arbitrary shapefiles as well as functions for rendering almost every map in the project. (The one exception is ZIP Code Maps, which are handled in the package choroplethrZip). The maps is renders are:

  • US states, counties and census tracts
  • Countries of the world
  • Administration level 1 maps (i.e. state / province maps) for each country

It also provides functions for getting and mapping data from the US Census Bureau and World Bank.

To install the latest version of choroplethr, type the following:


View package contents


The choroplethrMaps package contains many of the maps used by the Choroplethr package. The maps are:

  • US States
  • US Counties
  • Countries of the world

The US maps in this package from the US Census Bureau. The international map comes from Natural Earth Data.

To install the latest version of choroplethrMaps, type the following:


View package contents


The choroplethrAdmin1 package contains an Administrative Level 1 map of most countries of the world. “Administrative Level 1” is a general term for “the first level of division within a country.” In the US Administrative Level 1 regions are called “states”, in Canada they are called “provinces” and so on.

To install the latest version of choroplethrAdmin1, type the following:


View package contents


The choroplethrZip package contains a map and visualization functions for US Zip Code Tabulation Areas (ZCTAs). While ZCTAs are a good approximation of ZIP Codes, they are not identical: ZIP Codes are maintained by the US Postal Service and ZCTAs are maintained by the Census Bureau.

ZCTA / ZIP Code maps are complicated, and I dedicate three lessons of Mapmaking in R with Choroplethr to a discussion of this map.

Due to this package’s size (~60MB) it is hosted on github, not CRAN. To install the latest version of choroplethrZip, type the following:

# install.packages("devtools")
install_github('arilamstein/[email protected]')

View package contents


The rUnemploymentData package contains data and visualization functions for US Unemployment Data. The data comes from the US Bureau of Labor Statistics (BLS) Local Area Unemployment (LAU) datasets.

The data includes State and County data. The State dataset covers 2010-2013 and the County dataset covers 1990-2013.

To install the latest version of rUnemploymentData, type the following:


View package contents