Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Re-doing Reusable Scatterplot 101

Public visualization

Viewing a saved revision (read-only)

ab174a460f6249e2a9d7cc49b01b4717

Re-doing Reusable Scatterplot 101

0 stars1🌍 Public
AAlex
Last edited Apr 10, 2023
Created on Apr 7, 2023
Forked from Scatterplot 101

This example visualizes the Iris dataset as a scatterplot, encoding petal width on the x-axis and sepal length on the y-axis. It demonstrates a refactored version of a reusable chart module, building on an earlier commented-out implementation. The code uses D3 v7 APIs including `d3.csv` for data loading, `scaleLinear`, `extent`, `axisBottom`, `axisLeft`, and selection joins to render SVG circles. The final chart is assembled through a custom `scatterPlot` function configured with width, height, margin, and radius, then invoked on an SVG element.

AI-generated description