Fork of Fork of array to tree
✓ Published0🌍 Public
This example converts a shuffled array of numbers into a hierarchical tree visualization. Using d3.stratify to structure the data and d3.tree to compute node positions, it renders red-stroked circles connected by black paths in an SVG. Each circle displays its corresponding array value as text, with a staggered transition duration that varies by tree depth, animating the label appearance. The visualization updates in place, removing and re-adding elements as new arrays are generated.
AI-generated descriptionConverts an Array into tree.
MIT Licensed