County Level Analysis


This section looks at presidential election outcomes at the county level. County is the lowest geographical denomination for which complete presidential election results are available.

We start with a quick look at historical results from 1972 and then delve deeeper into potential correlates of voting outcomes.


1. Historical Maps


c_ele_n2012 <- subset(c_ele, !Year == "2012")

DM <- (lapply(split(c_ele_n2012, c_ele_n2012$Year), function(c_ele_n2012) {
  highchart() %>%
    hc_add_series_map(
      uscountygeojson, c_ele_n2012,
      name = "% Democrat", value = "Per_Dem1", joinBy = c("fips","FIPS1"),
      borderWidth = 0.1) %>%
    hc_title(text = unique(c_ele_n2012$title), style = list(fontSize = "12px", useHTML = TRUE)) %>%
    hc_colorAxis(dataClasses = color_classes(c(seq(0, 100, by = 50), 101), colors = c("red", c("#1874CD"), "white"))) %>%
    hc_legend(enabled = FALSE) %>%
    hc_tooltip(valueSuffix="%") %>%
    hc_add_theme(hc_theme_flatdark())
}))

hw_grid(DM, rowheight = 300, ncol = 2)  %>% browsable()