Question 4: Multi-Series Chart (Bar + Line)
✓ Published3🌍 Public
This example combines a bar chart and line chart into a single multi-series visualization, showing revenue as blue bars and units sold as a red line for each product category. The data is loaded as CSV from a remote GitHub gist and aggregated by product using d3.csv and manual JavaScript object mapping. The chart uses d3.scaleBand for the categorical x-axis and two separate d3.scaleLinear scales for the revenue and units y-axes, with d3.axisLeft for gridlines and d3.line to generate the units-sold path. The SVG is rendered with a gradient background and includes hover transitions on bars and circles.
AI-generated descriptionMIT Licensed