Skip to main content
100%

Coastal Graph Distance

✓ Published0🌍 Public
Mmbostock
Last edited Dec 24, 2019
Created on Mar 24, 2014

This map shows the graph distance of each US county from the Pacific or Atlantic coast, with coastal counties in dark blue and counties nine or more counties away in light yellow. It recreates a Reddit map using TopoJSON. The code calculates distances by iteratively expanding from coastal counties, using `d3.queue` to load the US GeoJSON and TSV data, `topojson.neighbors` for adjacency, and `d3.geoPath` to render SVG paths with a color scale from `d3.scaleOrdinal`.

AI-generated description

This map shows the graph distance of each county from the Pacific or Atlantic coast; it is a recreation of a map posted to /r/dataisbeautiful using TopoJSON. Coastal counties are dark blue, while counties nine or more counties away from the coast are light yellow. (I opted not to reuse the original’s cycling color scale.)

See also the underlying graph.

gpl-3.0 Licensed

Similar vizzes