Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

D3 sun-burst graph

Public visualization

D3 sun-burst graph

1 star1🌍 Public
SSubhendu Karmakar
Last edited Mar 13, 2024
Created on Mar 13, 2024

This example shows a sunburst visualization built from a small hierarchical dataset, where each ring segment represents a node in the tree and its angular width is proportional to the node’s value. The code uses D3 v7’s `d3.hierarchy`, `d3.partition` layout, and `d3.arc` to generate the radial paths, with semi-transparent dark fills and white strokes separating segments. While labels are commented out, the structure (root A1 with children B1 and B2, and nested leaves C1–D1) is clearly visible. The SVG is sized to the container and translated to center the chart.

AI-generated description

D3 Hierarchies

Comments

Sign in to join the discussion.

MIT Licensed