Viewing a saved revision (read-only)
fa18195d13fa458aa65b81325dd8c9ec
Fork of Loading and Parsing CSV Data
This example demonstrates the fundamentals of loading and parsing CSV data using D3.js version 5. It fetches the CSS Named Colors dataset from a GitHub Gist and displays a simple text summary of the file size in kilobytes, row count, and column count. The primary approach uses the `d3.csv` function to fetch and parse the remote CSV file, leveraging Promise-based asynchronous handling. The code also includes commented-out alternatives using native `fetch` with `async`/`await` and the `d3.csvParse` function, alongside a nested Promise "pyramid of doom" example. The output is rendered as large text within an HTML `<pre>` element.
AI-generated descriptionA program that loads and parses some CSV data: CSS Named Colors.
See also: