🌍 Public
Viewing a saved revision (read-only)
f1a60a3a396c4f789a9ea8c514368725
Loading and Parsing CSV Data
This example demonstrates loading and parsing CSV data from a remote URL using D3 v7. It fetches a dataset of CSS named colors and displays summary statistics, including the file size in kilobytes, the number of columns, and the number of rows, in a large text element. The code uses `d3.csv` to asynchronously load and parse the data, then `d3.csvFormat` to measure its length and `data.columns` to report the column count. A commented alternative shows using the Fetch API with `async`/`await` and `d3.csvParse`.
AI-generated descriptionA program that loads and parses some CSV data.