Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Line Chart with Multiple Lines

Public visualization

Line Chart with Multiple Lines

0 stars0🌍 Public
Pprincit
Last edited Apr 28, 2020
Created on Apr 28, 2020

This example displays CO2 emissions by country, plotting profit against sub-category over time, with each region represented by a distinct colored line. The visualization uses D3 v5 within a Vue framework, rendering to SVG. It employs `d3.line` with `curveBasis`, `d3.nest` to group data by region, and `d3.scaleOrdinal` with `schemeCategory10` for coloring. Axis labels and legends are added via `d3.axisLeft`, `d3.axisBottom`, and a custom `colorLegend` function, based on sample data from annualco2.csv.

AI-generated description

Comments

Sign in to join the discussion.

MIT Licensed