Skip to main content
100%

Scatter Plot with Color

✓ Published31🌍 Public
CCurran Kelleher
Last edited Oct 9, 2025
Created on Feb 23, 2023
Forked from Scatter Plot

This example visualizes the Iris Dataset as a scatter plot, with sepal length on the x-axis and petal length on the y-axis. The three species (setosa, versicolor, virginica) are distinguished by color using a categorical color scale with a legend. The visualization is built with D3.js, using `scaleLinear` for axes, `scaleOrdinal` and `schemeCategory10` for color mapping, and the selection `.join` pattern to manage SVG elements. Separate modules for axes and color legend keep the code modular.

AI-generated description

A scatter plot of the Iris Dataset with a color legend.

See also:

MIT Licensed

Similar vizzes