Parsing
✓ Published0🌍 Public
This example uses D3 v5 to parse a CSV file containing CSS named colors and displays facts about the dataset in large text. It first reports the data’s size in kilobytes, then the number of rows, and finally the number of columns. The code fetches the CSV from a remote URL using `d3.csv`, which returns a promise, then computes the statistics with `d3.csvFormat` and the array’s `.length` and `.columns` properties. Alternative approaches using `fetch` and `d3.csvParse` are included but commented out.
AI-generated descriptionA program that loads and parses some CSV data: CSS Named Colors.
See also:
MIT Licensed