Force Directed Graph Starter
✓ Published1🌍 Public
This example demonstrates a minimal force-directed graph with three nodes connected by two links using D3's force simulation. It shows how SVG circles and lines update their positions on each simulation tick. The code defines data arrays for nodes and links, then applies `d3.forceSimulation` with `forceManyBody`, `forceLink`, and `forceCenter` forces. Rendering targets an SVG container of 960 by 500 pixels, using the standard D3 data join pattern to manage elements.
AI-generated descriptionA D3 force simulation
See also React Starter.
MIT Licensed