Skip to main content
100%

Interactive Color Legend

✓ Published0🌍 Public
BBen Seebeck
Last edited Nov 9, 2021
Created on Nov 9, 2021

This interactive scatter plot visualizes the Iris dataset, encoding petal length and sepal width on the x- and y-axes with species as color. A legend built with SVG circles and text responds to mouse hover, fading unrelated data points and highlighting the selected species. The code uses React hooks (`useState`) to manage the hovered value, D3 scales (`scaleLinear`, `scaleOrdinal`) for positioning and coloring, with data loaded asynchronously via `d3.csv`.

AI-generated description

A scatter plot of The Iris Dataset.

MIT Licensed

Similar vizzes