Skip to main content
100%

Reuseable D3 Scatter Plot Exercise with Symbols

✓ Published0🌍 Public
Ppkdvalis
Last edited Dec 3, 2023
Created on Dec 1, 2023

This example demonstrates a reusable scatter plot that visualizes the Iris dataset, encoding petal width and sepal length on the x and y axes while using different D3 symbols to distinguish species. The chart is built as a custom `scatterPlot` function that leverages D3 scales like `scaleLinear` and `scaleOrdinal`, along with `axisLeft`, `axisBottom`, and the `symbol` generator to render SVG paths. Data is loaded asynchronously via `d3.csv`, and the plot is rendered into a full-window SVG using a React-compatible approach.

AI-generated description

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

See also React Starter.

MIT Licensed

Similar vizzes