Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Reuseable D3 Scatter Plot Exercise

Public visualization

Viewing a saved revision (read-only)

dbe9b3e603d1425b808f8fa60bc74b6f

Reuseable D3 Scatter Plot Exercise

0 stars2🌍 Public
Ppkdvalis
Last edited Dec 1, 2023
Created on Dec 1, 2023

This example demonstrates a reusable D3 scatter plot component built with React, visualizing the classic Iris dataset. It shows the relationship between petal width and sepal length, with a tooltip revealing the flower species on hover. The implementation uses `d3.scaleLinear`, `d3.extent`, `d3.axisLeft`, and `d3.axisBottom` to handle scaling and axes, while applying the component via a functional `.svg` selection call. The data loads from a remote CSV file, and the SVG resizes to fill the browser window.

AI-generated description

A bare minimum HTML page demonstrating use of CSS and JavaScript.

See also React Starter.