Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Fork of Loading Data

Public visualization

Viewing a saved revision (read-only)

3fa5679d274046dd9cc33f1ac01f613a

Fork of Loading Data

0 stars0🌍 Public
EEmily Hudson
Last edited Sep 3, 2025
Created on Sep 3, 2025
Forked from Loading Data

This example demonstrates the asynchronous loading of airline flight data from a CSV file, displaying the parsed contents as a JSON string in a preformatted text element. The visualization uses D3 v7’s `csvParse` method to convert the raw text into an array of objects, with numeric fields explicitly coerced to numbers. The code manages a state machine—starting as undefined, transitioning to `'LOADING'`, then resolving to the final dataset—by fetching `data.csv` via the Fetch API and updating the DOM through `select` and `.join` methods. The data source is a Kaggle dataset of airline flights, though the included file uses iris sample data for demonstration.

AI-generated description

This data set contains information about airlines and their flights. It includes details