Skip to main content
100%

City density filtering by population and proximity, Mercator

✓ Published0🌍 Public
AAlan McConchie
Last edited Aug 24, 2021
Created on Aug 11, 2021

This visualization filters city labels by population and proximity on a Mercator projection. Gray dots represent all cities from an OpenStreetMap dataset (tagged `place=city`), while highlighted dots show larger cities with smaller neighbors filtered out within a variable buffer radius. The example uses `d3.geoMercator` and `d3.geoPath` for mapping, `d3.scaleSqrt` for circle sizing, and `d3.scaleLinear` for buffer scaling. Country boundaries come from World Atlas TopoJSON, processed with the TopoJSON library. The algorithm applies a proximity-based filtering approach with variable buffer distances, demonstrating a method for decluttering dense point data.

AI-generated description

Experimental algorithm for filtering place labels.

Gray dots are all the cities in the input data, which are features from OpenStreetMap tagged with place=city. (Cities in India are missing from this dataset)

Highlighted dots show biggest cities with all their smaller neighbors (within a given radius) filtered out.

Country boundaries from World Atlas TopoJSON, polished for visual style. (That part forked from Sized Points on a Map)

ISC Licensed

Similar vizzes