Skip to main content
Public

Share visualization

Loading preview…

Scatter Plot with React & D3

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

Scatter Plot with React & D3

0
BBismark Kofi Owusu Sarfo
Last edited Sep 17, 2025
Created on Sep 17, 2025

This interactive visualization displays the Iris flower dataset, plotting sepal length over the dataset's row order. Users toggle between scatter plot and line chart views via React buttons, with species color-coded using d3.scaleOrdinal and a d3.schemeCategory10 legend. The D3 code builds linear scales, axes, and renders circles or a path using d3.line, while React manages state and the SVG element lifecycle.

AI-generated description

React D3 Line Chart Example

This project demonstrates how to create a line chart with React and D3 using the iris dataset with a time component added.

Comments

Sign in to join the discussion.

MIT Licensed