Skip to main content
100%

Untitled

✓ Published1🌍 Public
JJonas Carvalho
Last edited May 16, 2021
Created on Apr 4, 2021

This example loads a COVID-19 deaths time series from a GitHub-hosted CSV file using d3.csv, then displays summary statistics (kilobytes, column count, row count) via a React component. It uses React's useState and useEffect hooks to fetch and manage the data asynchronously, and the d3.range method to iterate once. The visualization ultimately renders a single face-like SVG shape—composed of circles with randomized eye, mouth, and stroke parameters—centered on a 960×500 canvas. The d3.csvFormat API is used to calculate the data size in kilobytes.

AI-generated description

Loading data with d3 and using react

MIT Licensed

Similar vizzes