Fork of React & D3 Starter
✓ Published1🌍 Public
This example combines a bar chart and line chart to compare solar and wind energy production from 2000 to 2182, sampling every tenth year for clarity. It uses React for the DOM structure and D3 v7 for SVG rendering, with `d3.scaleBand` positioning the bars, `d3.scaleLinear` mapping the y-axis, and `d3.line` drawing the wind energy trend overlaid with circular points. The data comes from a CSV file, and the chart includes gridlines, axis labels, and a legend to distinguish the two series.
AI-generated descriptionMIT Licensed