Skip to main content
100%

Summarizing Coronavirus Data

✓ Published0🌍 Public
MMichael Bruno
Last edited Feb 27, 2023
Created on Feb 24, 2023

This example displays the total global deaths from COVID-19 as a large red number in a `<pre>` element, updated to the most recent date in the dataset. It loads a CSV from the Johns Hopkins CSSE GitHub repository using `d3.csv`, extracts the last date column, sums all numeric values with `Array.reduce`, and formats the result with `d3.format`. The final message combines the comma-formatted total and the date, then injects it into the page via `textContent`.

AI-generated description
MIT Licensed

Similar vizzes