Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Map with selectable countries

Public visualization

Viewing a saved revision (read-only)

937033662d584034844fdfd455507b0d

Map with selectable countries

0 stars0🌍 Public
LLongYuu
Last edited Nov 29, 2020
Created on Nov 29, 2020

This example presents an interactive choropleth map of the world, where each country is colored according to its economic classification. Users can click on any country to highlight it, dimming all others, and click again to deselect. The map uses D3's `geoPath` and `geoNaturalEarth1` projection, with `scaleOrdinal` and `schemeSpectral` for the color scale. A separate legend allows filtering by economy value, and the zoom feature (`zoom()`) is included. Data comes from the `world-atlas` package, loaded with `tsv` and `json`.

AI-generated description

A bare minimum HTML page demonstrating use of CSS and JavaScript.

See also React Starter.