Animated Reusable D3 Scatter Plot
This example visualizes the classic Iris flower dataset as a scatter plot that cycles through different variable pairings every three seconds. Each circle represents a flower, with its position mapped to the selected x and y axes, and points animate smoothly to their new locations. The visualization uses D3 v7’s reusable module pattern, with `scaleLinear`, `axisLeft`, `axisBottom`, and `transition` to handle the animated updates of both circles and axes. The x-value changes among four measurement columns, while the y-value remains fixed, highlighting correlations between sepal and petal dimensions.