Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Fork of D3 Starter

Public visualization

Viewing a saved revision (read-only)

3987b76f70e843c58b5096dc07649d25

Fork of D3 Starter

0 stars0🌍 Public
Aa15923647
Last edited Nov 14, 2022
Created on Nov 14, 2022
Forked from D3 Starter

This example demonstrates how to add interactive brushing to a D3 visualization. It displays a single circle in an SVG element that changes color based on user selection: the circle turns green when it falls within the brushed area and pink otherwise. The code uses d3.brush to create the selection region and listens to brush events to trigger the updateChart function. Rendering occurs via SVG, with d3 v7 handling both the circle and brush interactions.

AI-generated description

A demonstration of how to start using D3 version 6.