Fork of Loading and Parsing CSV Data
✓ Published0🌍 Public
This example demonstrates how to load and parse CSV data using D3 v5 and the Fetch API. It displays the file size in kilobytes, the number of rows, and the number of columns from a dataset of CSS named colors. The code uses `d3.csv` for direct parsing and a commented alternative with `fetchText` and `d3.csvParse`. It highlights both the promise-based `then` pattern and the async/await approach, while avoiding the "pyramid of doom" by chaining promises.
AI-generated descriptionA program that loads and parses some CSV data: CSS Named Colors.
See also:
MIT Licensed