Geographic Distribution

Where your users are located

CodeCountry ShareUsers

The geographic-distribution card an analytics dashboard has, drawn by mappo. mappo draws the land, the borders and the sphere and hands out the projection; the per-country fills come from demo/countries.js: 228 countries keyed by ISO code, 24 KB gzipped, cut from the same pinned Natural Earth data as mappo's borders with the same simplifier, so they register with them vertex for vertex. The library does not ship keyed regions yet. It has country borders as one flat list of anonymous rings, which is enough to draw Brazil's edge and not enough to fill it in.

Hover a country for its number, or hover Other to see where the long tail is. A country too small to have a shape at this scale is a dot on its anchor. The controls redraw the same data as a globe, as a dot field, or in any of mappo's flat projections: on the flat map the fills are SVG over mappo's frame, and on the globe they are drawn through locate() cell by cell, the way mappo fills its own globe, with mappo's borders stroked over them the same way. More demos.