zorostang / chicago_bike_equity

Visualization and analysis of Chicago bike lanes. An effort to determine how the bike lane installations are divided among the entire city.
MIT License
20 stars 14 forks source link

How many grocery stores have a Divvy station nearby? #13

Closed stevevance closed 9 years ago

stevevance commented 9 years ago

Another problem we can solve with Turf.js.

guillermokrh commented 9 years ago

Hey Steven, I added a "turf-tests" branch, so I can show you what I'm trying to do with turf. Right now I'm struggling with iterating through the list of groceries to use them as comparison points in turf. For example, in the console right now I can access the latitude of the grocery store at index 0 of the groceriesGeojson feature list by typing in "groceriesGeojson.features[0].properties.LATITUDE". But when I try to use this information in the code, groceriesGeojson always turns up as undefined. Is there a better way of interacting with this data?

zorostang commented 9 years ago

@guillermokrh checkout my latest commit to turf-tests. I experimented with turf and divvy and was able to iterate through all the divvy stations and create 0.2 mile buffer regions using turf. This technique could probably be mimicked for the grocery stores.

guillermokrh commented 9 years ago

Thanks Gino I'll check it out!

stevevance commented 9 years ago

@zorostang Can you show me tomorrow? I'm gonna be coding tomorrow with you guys, something I haven't done for weeks because of...distractions at Hack Night.

stevevance commented 9 years ago

Done. @guillermokrh made it so the number would be calculated and then printed it to the console. See another issue for the next step.