Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Loading and Parsing CSV Data

Public visualization

Viewing a saved revision (read-only)

a9d85839d500425a9cccf93c0285e75f

Loading and Parsing CSV Data

0 stars0🌍 Public
SSam
Last edited Apr 25, 2021
Created on Apr 25, 2021

This example demonstrates how to load and parse CSV data using D3 v6 and the Fetch API. It retrieves a dataset of CSS named colors from a GitHub Gist, parses it with `d3.csvParse`, and displays a summary of the file size in kilobytes, the number of rows, and the number of columns. The code highlights alternative approaches, including `d3.csv` and async/await with `fetch`, while presenting the results in a large-text HTML element.

AI-generated description