Skip to main content
100%

Multiline chart with interaction

✓ Published0🌍 Public
PPriyaEnuganti
Last edited Jul 1, 2022
Created on Jul 1, 2022
Forked from HTML Starter

This example shows how South American countries’ annual changes in forest area have evolved over time, with each country represented as a distinct colored line. The chart uses React with d3.v5, rendering an SVG multiline chart with a time-scaled x-axis and linear y-axis. The code uses d3.line and d3.nest to structure the CSV data by entity, d3.scaleOrdinal and d3.schemeCategory10 for colors, and adds reactive tooltips via mouseover, mousemove, and mouseleave events on each path. The visualization includes a legend and title, with data loaded from a GitHub gist.

AI-generated description

A bare minimum HTML page demonstrating use of CSS and JavaScript.

See also React Starter.

MIT Licensed

Similar vizzes