-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
When GPS is within Chicago, use the Chicago Open Data portal. #3
Comments
This is the data I was talking about: https://data.cityofchicago.org/Facilities-Geographic-Boundaries/Boundaries-Neighborhoods/bbvz-uum9 |
@pjsier where's the api? |
It's a Socrata site, so they've got the endpoints set up according to this standard https://dev.socrata.com/ |
Actually looking at it now, not sure if they support geospatial queries. May have to either download the GeoJSON and put it on the site or somewhere else to query it |
Correction: sorry for the spam, but this might work: https://dev.socrata.com/docs/functions/within_circle.html it's a bad workaround, but they weirdly don't have a geospatial within, but this should work the same way |
If anything, it would be https://dev.socrata.com/docs/functions/within_polygon.html |
That's what I thought at first, but that's having the user create a polygon boundary as opposed to finding the polygon boundary. I figured using within_circle would be the easiest proxy for a point |
So I was playing around with it, and the neighborhoods map isn't actually available through the API at all. It's obviously not ideal, but I converted it to GeoJSON, and while it'd be too much to render it on the site, maybe we could put it in CartoDB or convert it to PostGIS? |
Turfjs is used with a static GeoJSON file (only about 150kb) to loop through all neighborhoods and print which one the point is within, otherwise returns "outside Chicago" |
No description provided.
The text was updated successfully, but these errors were encountered: