linechart Activity8_Task3
✓ Published0🌍 Public
This example displays a line chart of sales costs from 2000 to 2013, using a light green stroke to connect annual data points from a CSV file. The chart renders as an SVG with a red title and axis labels, using D3 v7’s `scaleBand` for the year axis and `scaleLinear` for the cost axis. A `d3.line` path positions points by adding half the band width to each year’s x-coordinate, while `d3.axisBottom` and `d3.axisLeft` generate the axes. The data includes a duplicate year (2008), which appears as two plotted points.
AI-generated descriptionA demonstration of how to start using D3 version 6.
MIT Licensed