Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

SunBurst

Public visualization

SunBurst

0 stars0🌍 Public
Vvivianaaai@qq.com
Last edited Nov 13, 2023
Created on Nov 13, 2023
Forked from D3.js 教程

This sunburst chart visualizes the population distribution of Xinjiang’s administrative regions, using nested arcs to show hierarchy from the province level down to districts and counties. The code relies on d3.arc for the ring segments, d3.partition with a size of [2*Math.PI, 500] to compute the layout, and d3.hierarchy to structure the JSON data. Each segment’s fill color is derived from the top-level region via a scaleOrdinal palette, and text labels are rotated and positioned to fit within the arcs.

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