Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Fork of Loading and Parsing CSV Data

Public visualization

Viewing a saved revision (read-only)

d8f6b7d7958a48d989abe730fe394cc5

Fork of Loading and Parsing CSV Data

0 stars0🌍 Public
AAerogirl10
Last edited Mar 1, 2021
Created on Mar 1, 2021

This example displays basic statistics about a CSV dataset loaded from a remote URL, showing the file size in kilobytes, 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 formats the results with `d3.csvFormat` and `Math.round`. The code also includes commented-out alternatives using the Fetch API with `async`/`await` and `d3.csvParse`, as well as a nested Promise-based approach. The page is a simple HTML document with D3 loaded from a CDN.

AI-generated description