Skip to main content
100%

Non-Contiguous Cartogram

✓ Published0🌍 Public
Mmbostock
Last edited Feb 13, 2020
Created on Nov 11, 2012

This example displays a non-contiguous cartogram of U.S. obesity rates, where each state is rescaled around its centroid so that its area encodes the data value while preserving local shape. The distortion is achieved by applying a `transform` attribute to each state path, using `d3.geo.path` to compute centroids and `Math.sqrt` to determine scale. State boundaries come from the U.S. Census Bureau. The code uses `d3.json` to load TopoJSON and `d3.select` to build the SVG scene.

AI-generated description

Unlike choropleth maps, cartograms encode data using area rather than color, resulting in distorted geographic boundaries. In this example, states are rescaled around their centroid, preserving local shape but not topology. Inspired by Zachary Johnson. Non-continguous cartogram design invented by Judy Olsen. U.S. state and county boundaries from the U.S. Census Bureau, simplified using GDAL and MapShaper.

gpl-3.0 Licensed

Similar vizzes