Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Untitled

Public visualization

Viewing a saved revision (read-only)

83f0f7a6312641249696a682e5456f83

Untitled

0 stars0🌍 Public
SStefan Apostol
Last edited Jan 14, 2023
Created on Jan 14, 2023
Forked from Upload data

This example demonstrates how to build a legend for bubble charts using SVG circles, dashed connector lines, and text labels. It shows three reference sizes (10, 50, and 100) positioned on a static canvas, with each label displaying placeholder text. The code uses d3.scaleSqrt() to map data values to pixel radii, then appends the legend elements via d3.selectAll().enter().append() in d3.v4. All rendering is done in a React-compatible HTML page, with the SVG object placed directly in the DOM.

AI-generated description

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

See also React Starter.