Skip to main content
100%

Interactive Color Legend

✓ Published0🌍 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
MIT Licensed

Similar vizzes