Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Reusable D3 Scatterplot

Public visualization

Reusable D3 Scatterplot

0 stars1🌍 Public
HHtet Yan Oo
Last edited Apr 30, 2024
Created on Apr 30, 2024

This reusable D3 scatterplot visualizes the Iris dataset, cycling through four flower measurements every two seconds to show different variable relationships. Built with D3 v7, it uses a custom scatterPlot function with `scaleLinear`, `extent`, `axisLeft`, and `axisBottom` to render SVG circles and axes. The animation loop calls `plot.xValue()` to dynamically swap the x-axis variable, demonstrating the reusable pattern’s flexibility. Data loads from a CSV via `d3.csv`, with coordinates recalculated on each update.

AI-generated description

Comments

Sign in to join the discussion.

MIT Licensed