Skip to main content
100%

Loading and Parsing CSV Data

✓ Published0🌍 Public
BBruno Simoes
Last edited Jun 29, 2021
Created on Jun 29, 2021
Forked from HTML Starter

This example demonstrates loading and parsing a CSV file with D3.js version 7, displaying the resulting row count, column count, and file size in kilobytes. It retrieves the data from a remote GitHub gist URL containing CSS named colors. The code uses `d3.csv()` to fetch and parse the remote CSV, then accesses the parsed data’s `.length` and `.columns` properties to extract the metadata. It also formats the data back to CSV with `d3.csvFormat()` to compute the data size, and outputs the statistics in a large `<pre>` element.

AI-generated description

A program that loads and parses some CSV data.

MIT Licensed

Similar vizzes