counties(state = NULL, cb = FALSE, resolution = "500k", detailed = TRUE,
...)
refresh
, which specifies whether or not to re-download shapefiles
(defaults to FALSE
), and year
, the year for wblock_groups
;
blocks
; places
;
pumas
; school_districts
;
states
; tracts
;
zctas
library(tigris)
library(ggplot2)
library(ggthemes)
me <- counties("Maine", cb = TRUE)
me_map <- fortify(me)
gg <- ggplot()
gg <- gg + geom_map(data=me_map, map=me_map,
aes(x=long, y=lat, map_id=id),
color="black", fill="white", size=0.25)
gg <- gg + coord_map()
gg <- gg + theme_map()
gg
Run the code above in your browser using DataLab