Melting Data for Multiple Lines
✓ Published0🌍 Public
This example shows animated multi-line charts tracking COVID-19 confirmed cases over time for several countries, with colored lines that progressively extend as the day counter advances. A legend and axis labels accompany the visualization. The code uses d3.nest() to group data by country, d3.line() with curveBasis for smooth paths, and d3.scaleLinear for x/y axes. Circle markers and text labels display the latest value of each line. Data comes from CSV files processed through a custom loadAndProcessData function.
AI-generated descriptionMIT Licensed