Reusable D3 Scatter Plot
This reusable scatter plot visualizes the Iris Dataset, showing relationships between sepal and petal measurements across four variables. The code uses d3.scaleLinear, d3.extent, d3.axisLeft, and d3.axisBottom to map data points to SVG circles. A setInterval cycles the x-axis through different dataset columns every two seconds, animating the scatter plot’s configuration. The chart is built as a reusable function following the "Towards Reusable Charts" pattern, with configurable width, height, margins, radius, and accessor functions.