Skip to main content
Public

Share visualization

Loading preview…

loading_data_NH_2

vizhub.com

Shared links may look like this on X, LinkedIn, Slack, and Discord.

Before sharing, review the publishing checklist.

Choose how to deliver this visualization

LinkedIn caption

LinkedIn may not keep text supplied by the share sheet. Copy the caption and paste it into the post if needed. You can tag the VizHub company page when posting.

More options

Embed on a websiteCopy iframe embed code
Download & exportPNG, HTML, source ZIP

loading_data_NH_2

3
NNavak94
Last edited Jan 23, 2023
Created on Jan 23, 2023
Forked from Mouse Follower

This example demonstrates asynchronous data loading with D3 v7, displaying the contents of a CSV file as formatted JSON text in a pre element. It uses `fetch()` to retrieve `data.csv`, `csvParse` from D3 to convert the raw CSV string into an array of objects, and then iterates through the parsed data to coerce the numeric columns (`sepal_length`, `sepal_width`, `petal_length`, `petal_width`) from strings to numbers. The visualization implements a unidirectional data flow where a `setState` function updates the application state, triggering a re-render that initially shows "LOADING" before the fetched data appears.

AI-generated description

A circle that follows the mouse using unidirectional data flow.

Comments

Sign in to join the discussion.

MIT Licensed