Skip to main content
100%

D3.js Line Chart and Stacked Bar Chart

✓ Published0🌍 Public
Mmdadeebfarhaan@gmail.com
Last edited Apr 26, 2024
Created on Apr 26, 2024
Forked from Hello VizHub

This example visualizes COVID-19 data for the state of Kerala using two D3.js v7 charts. A line chart traces confirmed cases over time, with red dots and interactive tooltips showing exact dates and counts. Below it, a stacked bar chart breaks down the same data into confirmed, cured, and death categories. The visualization loads data from a remote CSV via `d3.csv`, uses `d3.scaleTime` and `d3.scaleLinear` for axes, and renders with SVG paths, circles, and animated tooltip transitions.

AI-generated description

An example showing the capabilities of VizHub:

  • Loads D3 via UNPKG.
  • Demonstrates use of import from "d3".
  • Demonstrates use of import from local ES6 modules.
MIT Licensed

Similar vizzes