Skip to content

datascopeanalytics/chicago-new-business

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

86 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

chicago-new-business

Visualize where new businesses are created in the city

quickstart

  1. Create a python virtualenv with virtualenvwrapper

    mkvirtualenv chicago-new-business
    workon chicago-new-business
  2. Install python dependencies

    pip install -r requirements/python
  3. Sign up for Google Maps Geocoding API and get key. Store key in src/google_api.py as below

    google_api_key = "YOUR_API_KEY"
  4. Run the data analysis pipeline using flo

    flo run
  5. Enjoy the static figures.

    open data/*.png
  6. View the site.

    cd web && python -m SimpleHTTPServer
    # open http://localhost:8000 in your browser

appendix

To convert shapefiles into TopoJSONs used in viz:
  1. Install topojson command-line application.

  2. Run following commands in /data/boundaries directory.

    # The -t_srs crs:84 specifies a projection to use. If you leave this part off, you won't be dealing with degrees in your output document.
    ogr2ogr -f "GeoJSON" -t_srs crs:84 neighborhoods.json Neighborhoods_2012b.shp
    # Convert to TOPOJSON; specify ID and retain property with -p
    topojson -o neighborhoods.topojson --id-property PRI_NEIGH -p SEC_NEIGH  -- neighborhoods.json

About

Visualize where new businesses are created in the city

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published