I am new to Leaflet.js.
Is it possible to create a choropleth using zip-code level data?
I've seen plenty of choropleth examples using state-level data and even a few using county-level data.
If so, what would be a good way to go about it using Leaflet?
Do I need to obtain coordinates for the shapes of each zip code I'm interested in visualizing?
Best Answer
Get a polygon feature class of the zip codes that you want to add
Store your polygon zip code feature class in a RDBMS like PostGIS
Encode your polygon zip code geometry objects to GeoJSON objects
Create a GeoJSON layer and populate it with your GeoJSON objects
Use the polygon extension of the path abstract class from Leaflet documentation to symbolize fill color, opacity etc. based on data either supplied by user or from your polygon feature class.