Skip to content

Instantly share code, notes, and snippets.


eyeseast/census3nicar14 Secret

Forked from jkeefe/census3nicar14
Last active Jan 8, 2016
What would you like to do?
Get the data ....
Census Reporter ... GEOJSON or CSV
- For example: Age by Language Spoken at Home for the Population 5 Years and Over
- Download here,05000US25025,31000US14460,04000US25,01000US,160|04000US25&primary_geo_id=16000US2507000#
- Everything is zipped and comes with metadata.json (contains fieldnames and such)
- topojson will make this geojson smaller, but make sure you preserve properties!
US Atlas
- Mike Bostock collected a bunch of GIS resources in one place
- Everything is in the Makefile. Just git clone and make.
Caveat: Node Canvas is a pain to install. If it gives you trouble, comment it out in package.json before you make.
Fusion Tables
- Easy
- Usually free
- You have it already
- Good for fast, quick, low-data maps
CREATE -> Fusion Table
upload the census data
Next you need the shapes
Census Shapefiles
But you need them to be in KML for Google
One way is to use CartoDB to upload then Export
Using Export to download
CREATE -> Fusion Table
upload the KML
(I did it already, so it's in my account)
Join the tables together with file -> Merge
Style them with the buttons on the left
Embed them with SHARE
- Friendly interface
- Free to tinker (otherwise paid)
- Great team / support
- Handles bigger data pretty well
- We like it for internal draft maps for reporters
Show median income with wizard
Life in the Middle story
The map Jenny Ye made with aSQL statement:
SELECT * FROM life_in_the_middle_merge WHERE median_income < '52865' AND median_income > '50865'
Show sharing with URL
Mapbox / Tilemill
- Complete style control
- Rendered ahead of time
- Superfast load, even on mobile
- Great for high-data maps
Median income across the US
- Can change shapefiles
- Billions of other things
- For that moment when you need to change / blend / reproject
Remove water from census trick outlined here:
- Start with GeoJSON (or topojson and unpack it). Leaflet knows how to deal with GeoJSON out of the box:
- I use [d3.scale.quantize]( and [colorbrewer]( but you don't have to.
- Example, inequality by county:
D3 svg
- Start with GeoJSON (or topojson and unpack it)
- Mike Bostock has a [good tutorial here]( on mapping with D3.
- For choropleth maps, again, use [d3.scale.quantize]( and [colorbrewer](
- Example, mapping states:
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.