Map Virginia 1: Extracting OSM Data for a Localized Map Server Revisited

The Problem

In the 2016 U.S. general election Hillary Clinton received 1,981,473 votes to Donald Trump’s 1,769,443 votes, winning the state [1]. The Democratic party has won each of the last three presidential contests, yet despite getting the majority of the votes statewide, Democrats control only four of the eleven congressional seats in what Wikipedia describes as “one of the most gerrymandered states in the country” [2]. It had previously been only three of the eleven seats, but a court ordered redistricting this past year led to a gain of one seat by the Democrats. The Virginia House of Delegates is equally skewed, with Republicans controlling 66 of 100 seats and 21 of 40 seats in the lower and upper houses respectively [3].

The goal of this project will be to see what contribution a civic hacking group can make to help to counteract this anti-democratic reality. As described in David Daley’s book, Rat F**ked: The True Story Behind the Secret Plan to Steal America’s Democracy, insightful Republican operatives used a combination of political and geospatial analysis to scientifically control the rules of the U.S. electoral game, while the mostly ignorant Democrats got taken by surprise and beaten badly, despite their numerical superiority.

As the U.S. becomes increasingly unequal and our democracy continues to erode, any chance of saving it will require the collaborative efforts of large numbers of us who constitute the vast majority of “the people” yet who lack the financial resources to compete with those in power using the rules they create. Can we leverage collaborative effort and shared resources to effectively fight back? Let’s see.

The Plan

The goal will be to use data and geospatial analysis tools to help empower democratic forces in Virginia to more effectively participate in the electoral process. Since these tools and techniques will need to be collaborative to be effective, only free software and open data will be utilized.

Creating the Database

A databased named map_virginia can be created using the same process described in Map Arlington 1: Extracting OSM Data for a Localized Map Server. The step using osmosis to extract a part of the Virginia data can be skipped, since we are interested here in the entire state.

Viewing the Database in QGIS

The PostGIS data can be viewd in QGIS by creating a connection to the database from QGIS:

Connecting QGIS to PostGIS database

and then browsing the layers:

Map Virginia database in QGIS

The next task will be to begin assembling the data needed to reason about voters and elections.

Footnotes