Skip to main content
100%

Pulling Live Coronavirus Data

✓ Published1🌍 Public
CCurran Kelleher
Last edited Mar 28, 2020
Created on Mar 28, 2020

This example displays a line chart of global cumulative coronavirus deaths over time, using a logarithmic y-axis to accommodate the wide range of values. It loads live data from the Johns Hopkins COVID-19 dataset via `d3.csv`, parsing dates with `d3.timeParse`. The React components render SVG elements, with `d3.scaleTime` for the x-axis and `d3.scaleLog` for the y-axis. Axes are drawn using `d3.axisBottom` and `d3.axisLeft`, while the line path is generated with `d3.line`. Gridlines and tick labels are styled via CSS in the embedded `<style>` block.

AI-generated description

Line chart of Coronavirus cases to date. Data from Johns Hopkins Coronavirus Dataset.

MIT Licensed

Similar vizzes