Skip to main content
100%

Animated Scatter Plot with Menus

✓ Published1🌍 Public
GGautier DAVID
Last edited Dec 22, 2023
Created on Dec 21, 2023

This interactive scatter plot lets users explore the classic Iris dataset by dynamically changing which measurements are plotted on the x and y axes. Dropdown menus update the chart's axes, and the plotted circles smoothly transition to their new positions over time. Built with D3.js, the visualization uses menu component events to redraw the plot, relying on D3's scaleLinear for axes and transition for the animated updates.

AI-generated description

Continuing on the previous episode, on this one we see how to add menus to the charts.

Allowing us to select different column for x and y axis to update the data displayed on those axis.

Use of :

-selection.dispatch() => to dispatch an event

-selection.on() => to listen to an event

MIT Licensed

Similar vizzes