Skip to main content
100%

Loading and Parsing CSV Data

✓ Published0🌍 Public
Yyanaltingliu
Last edited Nov 3, 2021
Created on Nov 3, 2021
Forked from HTML Starter

This example demonstrates how to load and parse a remote CSV file using D3 v7. It fetches the CSS-named-colors dataset from a GitHub gist, then 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` for direct loading and parsing, with an alternative commented-out approach using `fetch`, `async`/`await`, and `d3.csvParse` to show manual text handling. The output is rendered as plain text inside a `<pre>` element.

AI-generated description

A program that loads and parses some CSV data.

MIT Licensed

Similar vizzes