ICE 7 - Reusable Scatter Plot
This example presents a reusable scatter plot built with React and D3, visualizing the Iris dataset. It displays petal width against sepal length, with points colored by species (red for setosa, black for versicolor, green for virginica). The visualization includes axes and labels, and cycles through different column pairings every 140 milliseconds, animating the scatter plot as it updates the x and y values. The code uses D3’s `scaleLinear`, `extent`, `axisLeft`, and `axisBottom` to handle scaling and axes, rendering SVG circles via a custom `scatterPlot` function.