Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Interactive Color Legend

Public visualization

Interactive Color Legend

0 stars0🌍 Public
TTaweewat Somboonpanyakul
Last edited Jun 24, 2021
Created on Jun 24, 2021

This interactive scatter plot displays the Iris dataset, plotting petal length against sepal width with points colored by species. The color legend on the right is interactive: hovering over a species name fades all other points to 20% opacity, highlighting the selected group. The visualization uses React and D3 v6, leveraging `scaleOrdinal` for categorical colors, `scaleLinear` for axes, and SVG circles. Hovering over data points reveals tooltips via SVG `<title>` elements, while the legend’s `onMouseEnter` and `onMouseOut` handlers drive the filtering logic.

AI-generated description

Comments

Sign in to join the discussion.

MIT Licensed