Skip to main content
100%

Animated Reusable D3 Scatterplot

✓ Published1🌍 Public
HHtet Yan Oo
Last edited May 2, 2024
Created on Apr 30, 2024

This example demonstrates an animated scatterplot of the Iris dataset, cycling through different x-axis variables every three seconds. It shows how a reusable D3 chart function can update its scales, axes, and data bindings dynamically. The code imports specific D3 modules like `csv`, `scaleLinear`, `axisLeft`, `axisBottom`, and `transition`. Circle positions and axis titles animate smoothly using D3 transitions, while a `setInterval` loop triggers calls to the scatter plot function with different column mappings, creating a looping exploration of the dataset’s features.

AI-generated description
MIT Licensed

Similar vizzes