Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Sized Points on a Map

Public visualization

Viewing a saved revision (read-only)

54b508e278ee4dd19a1ab1e168ef62db

Sized Points on a Map

0 stars0🌍 Public
JJoel Schwartz
Last edited Jun 9, 2020
Created on Jun 9, 2020

Two legends demonstrate how to encode data with color and size scales on an SVG map. The color legend uses a `d3.scaleOrdinal` to map fruit categories to distinct colors, while the size legend applies a `d3.scaleSqrt` to represent numeric values through circle radii. Both legends are rendered with custom functions, `colorLegend` and `sizeLegend`, which append groups containing circles and text labels.

AI-generated description