Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Loading and Parsing CSV Data

Public visualization

Viewing a saved revision (read-only)

16a74c72e02e4a0cb0791144a9dcd8f9

Loading and Parsing CSV Data

0 stars1🌍 Public
MMichael Bruno
Last edited Feb 15, 2023
Created on Feb 15, 2023

This example demonstrates how to load and parse CSV data using D3 v5. It fetches a dataset of CSS named colors from a GitHub gist and displays basic statistics about it—file size in kilobytes, row count, and column count—in a large HTML text element. The code uses `d3.csv()` with a Promise chain, and also includes commented-out alternatives using the Fetch API with `async`/`await` and `d3.csvParse()`. The visualization simply presents these numeric summaries as plain text, without any graphical chart or color rendering.

AI-generated description