Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Pie Chart

Public visualization

Viewing a saved revision (read-only)

aa30d767e1c74be5a92f03fdd44191d2

Pie Chart

0 stars0🌍 Public
Pprajoth0405
Last edited Mar 27, 2022
Created on Mar 27, 2022
Forked from Pie Chart

This pie chart visualizes the population distribution across U.S. states, using a categorical color scale for each state. The D3.js code loads CSV data from a Gist, calculates each state's share via the `pie` layout, and renders SVG slices with `arc` paths. A legend translates each sector's value into abbreviated format (e.g., "K" for thousands), while the chart is generated with `scaleOrdinal` for colors and D3's `format` for tick labels.

AI-generated description