uscensusbureau / citysdk

Convenient JavaScript utilities for working with Census APIs: Statistics, Cartographic GeoJSON, lat/lng -> FIPS, and other niceties (written in ClojureScript)
https://uscensusbureau.github.io/citysdk
MIT License
969 stars 183 forks source link

Provide new functions and example for US State Query Builder #266

Closed jmeisel closed 5 years ago

jmeisel commented 8 years ago

Right now it's easy to pull data within a state at a lower boundary, but hard to pull data for all the US States. (because State is the highest level geography supported by CitySDK). This prevents users from easily creating a US Map and showing state vs state comparisons using a heatmap or choropleth.

Recommendation is to allow for new functions to CitySDK and accompanying "US State Query Builder" that returns State Demographic Data and associated State boundaries. Since the parameters would be limited to State data only, the data could also be cached to ensure it's always available.

Example of how easy it is to do in R is available here, which reminded me of this current product gap in CitySDK:
https://github.com/jmeisel/Census-Data-Science-Workshop/wiki/Exercise-2:-Fracking-Impact-on-Per-Capita-Income-in-North-Dakota-(R-Studio)

loganpowell commented 5 years ago

Hi @jmeisel ! We are now using generalized boundary files, so making choropleths is a snap. Here's an example for you (all ZCTAs in the US):

https://uscensusbureau.github.io/citysdk/examples/mapbox/zip-code-tabulation-areas_static/index.html

it's a huge file, so give it some time to load ;)

miss ya boss