Skip to main content
100%

Fork of Loading and Parsing CSV Data

✓ Published0🌍 Public
CChestnut Sea
Last edited Feb 26, 2023
Created on Feb 26, 2023

This example demonstrates loading and parsing CSV data from a remote URL, displaying the file size, row count, and column count in large text. It uses D3 v5’s `d3.csv` method to fetch and parse the CSS Named Colors dataset, then computes metrics from the parsed array and its `.columns` property. The code also includes commented-out alternatives using `fetch` with `async/await` and `d3.csvParse`, highlighting different approaches to asynchronous data loading. The rendered output is a simple HTML `<pre>` element updated via the DOM.

AI-generated description
MIT Licensed

Similar vizzes