Question 1: Reusable Scatter Plot
✓ Published2🌍 Public
Sshreshnaanugu@gmail.com
Last edited Oct 27, 2025
Created on Oct 27, 2025
Forked from Question 4: Multi-Series Chart (Bar + Line)
This example demonstrates a reusable scatter plot function that visualizes sales data across two separate charts, encoding x and y values with a linear scale and coloring points by category using `d3.scaleOrdinal` with `d3.schemeCategory10`. The code defines a configurable `scatterPlot()` factory function that accepts custom accessors for axes, title, labels, and radius, then renders SVG circles with gridlines, transitions on hover, and a gradient background. Built with D3 v7 and styled via CSS, it illustrates how to create modular, parameterized chart components for repeated use with different datasets.
AI-generated descriptionMIT Licensed