Choropleth map interactive filtering
✓ Published1🌍 Public
This example presents a choropleth map of the world, where countries are colored according to their economy using a spectral color scale. The map supports interactive filtering: hovering highlights a country, and clicking a legend item dims all countries except those matching the selected economy category. The visualization is rendered as SVG using d3.geoPath with a geoNaturalEarth1 projection, while the color legend is built with d3.scaleOrdinal and d3.schemeSpectral. Country data comes from the world-atlas TopoJSON dataset, merged with TSV metadata. The zoom and pan interaction is enabled through d3.zoom, applying event.transform to the map group.
AI-generated descriptionMIT Licensed