Skip to main content
100%

Loading and Parsing CSV Data

✓ Published0🌍 Public
TTsaikkari
Last edited Jul 26, 2021
Created on Jul 25, 2021
Forked from HTML Starter

This example demonstrates how to load and parse CSV data from a remote URL using D3 v5. It displays the file size in kilobytes, the number of rows, and the number of columns in a large text element. The code uses `d3.csv` to fetch and parse the data, then accesses the resulting array’s `length` and `columns` properties. It also relies on `d3.csvFormat` to compute the formatted size, with an alternative commented approach using `fetch`, `async/await`, and `d3.csvParse`. The data comes from a GitHub gist containing named colors.

AI-generated description

A program that loads and parses some CSV data.

MIT Licensed

Similar vizzes