Maps


New Organizing Institute 
Data Bootcamp 2014


Noah Glusenkamp
cofounder | Empower Engine

ObjectiveS



By the end of today you will be able to:

  • make maps!
  • advocate for time /resources to make maps
  • see the range of what's possible with geo-spatial
  • find where to learn more




WHy Make maps?

Maps Help US


  • communicate information quickly
  • see geographic patterns in data
    • office locations
    • volunteer to voter demographics pairing
  • motivate people
    • this is near me, this is possible
    • I'm a part of this, I belong
    • this region needs to do more work
  • convince people 
    • model scores & local geo-based knowledge
  • debug field programs


There's 

no such thing 

as a 

viral excel sheet


- Ben Blatt,  Slate



       
>



*sometimes

Prop 1: Car Tabs Increase for TRANSIT 

King County, WA (2014)

Map by Benjamin Anderstone, anderstone.com

Number of Jobs Accessible by Transit


Map by Brandon Martin-Anderson, Conveyal



"Our displays of evidence 
should be worthy of the 
spectacular resolution
of the human eye-brain system"

- Edward Tufte

Spatial Data



raster

image from mapschool.io

Spatial Data



vector


image from mapschool.io

Latitude & Longitude




image from mapschool.io

Geocodes



look up the lat, lon for and address




GEOCODES


Allow you to put points on a map

Free Geocoders: 
gpsvizualizer.com, Texas A&M, Census Bureau, PostGIS Tiger Geocoder

Vector Data Formats


Shapefile
WI_precincts.zip  contains:
WI_precincts.shp 
WI_precincts.prj
WI_precincts.shx
WI_precincts.dbf


GeoJSON, KML

Projections

 it turns out  that
the earth is not a perfect sphere

image from giscommons.org/earth-and-map-preprocessing

PROJECTIONS

and maps are usually 2D "flatland"

image from kidsgeo.com

PROJECTIONS



Map data usually comes in a certain projection.

The projection you use determines your distance units.

The important thing is to make sure you're using the same projection when mapping two data sets.




PROJECTIONS

thankfully, QGIS makes this easy to do

Features and Attributes



image from www.indiana.edu/~gisci/courses/g338/lectures/attributes.html




QGIS ExerCISE

FEATURES AND ATTRIBUTES



image from www.indiana.edu/~gisci/courses/g338/lectures/attributes.html

...or Just Rows with  

COLUMN FOr GEOMETRY 


Spatial Database




Oracle Spatial, SQLServer Spatial
 ESRI Personal Geodatabase (.mdb), SpatialLite

Querying

in QGIS 
"num_persons" < 500

Spatial JoinS


location is the universal key

e.g. points in polygon
apply districts,  aggregate values/counts
image from http://wtlab.iis.u-tokyo.ac.jp/~wataru/lecture/rsgis/giswb/vol2/cp4/cp4-7.htm

Spatial JOins

or
UPDATE  hex.wa_voters_lat_long
SET prec_2013_district_id=precincts_2013.district_id
FROM hex.precincts_2013
WHERE ST_CONTAINS(precincts_2013.geometry, wa_voters_lat_long.point); 

There's Plenty More to learn


Map Design 
symbology, data classification, color schemes/scales

Spatial Analysis
buffers, complex joins, view-sheds

Spatial statistics / machine learning
surfaces & other crazy-raw shit

Made with Slides.com