Fork of Interactive Color Legend
✓ Published0🌍 Public
This example visualizes the Iris Dataset as a scatter plot using D3 v7, displaying sepal length versus petal length with points colored by species via `scaleOrdinal` and `schemeCategory10`. A color legend renders each species as a labeled circle using `colorLegend`, and hovering over a legend tick dynamically adjusts the opacity of matching scatterplot marks through `setHoveredValue` and `hoveredValue` state. The visualization uses D3’s `selection.join`, `scaleLinear` for axes, and `csvParse` for data loading.
AI-generated descriptionA scatter plot of the Iris Dataset with a color legend.
Hover on the color legend to highlight the marks that match!
See also:
MIT Licensed