Skip to main content
100%

Fork of D3 v5 Zoomable Sunburst

✓ Published0🌍 Public
Sstevendo1988
Last edited Nov 7, 2022
Created on Nov 7, 2022

This visualization displays a zoomable sunburst chart of the Flare data hierarchy, using D3 v5 and the Observable standard library. The chart presents hierarchical data as concentric arcs, with the root node at the center and children radiating outward. Users can click on any segment to zoom into that level, which smoothly animates the transition to show the selected branch in detail. The code employs D3's `d3.partition`, `d3.arc`, `d3.hierarchy`, and `d3.interpolate` functions, combined with `transition.attrTween` for animated updates. Each segment is color-coded by its top-level category, and labels appear for sufficiently sized arcs.

AI-generated description

Mike Bostock's D3 Zoomable Sunburst example

<br></br> Ported from this Observable notebook for this forum thread. Many thanks to Bryan Gingechen who answered my question about the necessary steps to get from an (Observable) JavaScript notebook to a vanilla JavaScript index.html. He presented his solution on blockbuilder.org

MIT Licensed

Similar vizzes