Skip to main content
100%

Loading and Parsing CSV Data

✓ Published0🌍 Public
Ddjfeld01
Last edited Feb 27, 2021
Created on Feb 27, 2021
Forked from HTML Starter

This example demonstrates the loading and parsing of CSV data using D3 v6, displaying the file size, row count, and column count in a large text element. The code fetches a CSV file from a GitHub gist containing named CSS colors and processes it with `d3.csv()`, which returns a promise. The results are formatted using `d3.csvFormat()` to calculate the data’s kilobyte size, while `data.length` and `data.columns.length` report the row and column totals. A commented section also shows an alternative approach using the Fetch API and `d3.csvParse()`.

AI-generated description

A program that Loads and Parses some CSV Data

MIT Licensed

Similar vizzes