Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

ICE8-1.2

Public visualization

ICE8-1.2

1 star1🌍 Public
Kkartik900
Last edited Apr 13, 2023
Created on Apr 13, 2023
Forked from HTML Starter

This example renders a choropleth-style map of U.S. states using a categorical color scale based on state names. It uses D3 v5’s `d3.geoAlbersUsa` projection and `d3.geoPath` to draw state boundaries from TopoJSON data loaded from the us-atlas CDN, with state labels positioned at each polygon’s centroid. The code also applies a sequential color palette via `d3.scaleOrdinal` and `d3.schemeCategory10`, and includes hover tooltips via appended `title` elements. The map is rendered as SVG, with black stroke outlines for each state.

AI-generated description

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

See also React Starter.

Comments

Sign in to join the discussion.

MIT Licensed