Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

D3 Starter

Public visualization

Viewing a saved revision (read-only)

60d43564f2584fc6a173cf45c1f3c3b5

D3 Starter

0 stars0🌍 Public
YYujunliu95
Last edited Apr 6, 2023
Created on Apr 6, 2023
Forked from D3 Starter

This example demonstrates three different layout methods for hierarchical music data—a labeled tree layout, an interactive force-directed graph, and a subtree view—all rendered as SVG. The data is read from a CSV file containing record labels, artists, and albums, converted into a hierarchy. The code uses D3 v7’s `tree`, `hierarchy`, `linkHorizontal`, and `forceSimulation` APIs to construct the layouts. The force-directed version includes dragging interactions via `drag`, allowing users to reposition nodes while the simulation updates positions on each tick.

AI-generated description

A demonstration of how to start using D3 version 6.