Skip to main content
Public

Share visualization

Loading preview…

Iris Dataset Scatter Plots with Color Legend

vizhub.com

Shared links may look like this on X, LinkedIn, Slack, and Discord.

Before sharing, review the publishing checklist.

Choose how to deliver this visualization

LinkedIn caption

LinkedIn may not keep text supplied by the share sheet. Copy the caption and paste it into the post if needed. You can tag the VizHub company page when posting.

More options

Embed on a websiteCopy iframe embed code
Download & exportPNG, HTML, source ZIP

Iris Dataset Scatter Plots with Color Legend

0
Sstephanie0215
Last edited Sep 28, 2022
Created on Sep 24, 2022
Forked from Scatter Plots

This visualization displays the Iris dataset as a scatter plot of petal length versus petal width, with each of the three flower species (setosa, versicolor, virginica) distinguished by a distinct color from a D3 ordinal scale. Using D3 v7, the code loads CSV data, scales the x and y axes with `scaleLinear`, and renders circles as data points. Axes are generated with `axisBottom` and `axisLeft`, and the SVG output includes a color legend that maps class labels to specific hex color values.

AI-generated description

T

Comments

Sign in to join the discussion.

MIT Licensed