Skip to main content
100%

Loading Data with React and D3

✓ Published0🌍 Public
DDaniel
Last edited Aug 10, 2023
Created on Aug 10, 2023
Forked from Mouse Follower

This gallery example demonstrates how React and D3 can work together to fetch and summarize a CSV dataset from a remote URL. The visualization shows a plain-text summary of the data, displaying its size in kilobytes, row count, and column count. The code uses React’s `useState` and `useEffect` hooks to manage the asynchronous data loading, while D3’s `csv` function parses the file from the provided gist URL. A custom `message` utility formats the three statistics using `d3.csvFormat` and the parsed data’s properties, rendering the result inside a `<pre>` element.

AI-generated description

loading data tutorial

MIT Licensed

Similar vizzes