Trying to take GIS data of the zip codes of the Bronx and turn it into a map using d3.js. But I am having trouble rendering. Could you show me proper use of d3.geo.path() ?
[ [ -73.84463693999993, 40.90475939500004 ], [ -73.84443733899991, 40.90423928800004 ], [ -73.84443555299993, 40.904234630000076 ], [ -73.84332154899994, 40.90397722300008 ],...]
These numbesr are taken from NYC zip codes map: https://nycopendata.socrata.com/Social-Services/Zip-Codes-Map/zsjh-u7ve
In fact, this question goes for any list of GIS coordinates. How do I turn it into a path? I could not convert the documentation this into code. https://github.com/mbostock/d3/wiki/Geo-Paths
Best Answer
I assume these coordinates trace out a polygon boundary? The easiest thing to do is to turn the coordinate list into GeoJSON
Now you create a path generator and use that create your svg for d3.