Skip to main content
100%

D3 Bubble Visualization

✓ Published0🌍 Public
VValentin Edelsbrunner
Last edited Sep 21, 2023
Created on Sep 21, 2023
Forked from HTML Starter

This example shows a force-directed bubble visualization with 30 nodes constrained inside a circular boundary. Nodes belonging to the "inside" group are randomly sized and remain confined within the bubble's radius, while "outside" nodes are smaller and free to move. Using d3.forceSimulation with charge, center, and collide forces, the simulation updates node positions on each tick, rendering SVG circles via join operations. The code draws circles with D3 v6 and applies clamping logic in the tick function to keep inner nodes within the gray circular outline.

AI-generated description

A bare minimum HTML page demonstrating use of CSS and JavaScript.

See also React Starter.

MIT Licensed

Similar vizzes