Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Read in csv with d3

Public visualization

Read in csv with d3

0 stars0🌍 Public
Ddmr
Last edited Nov 13, 2021
Created on Nov 13, 2021

This example demonstrates how to fetch and parse a CSV file from a remote URL using D3 v3. It shows the file’s size in kilobytes, row count, and column count as plain text on the page. The code uses the Fetch API to retrieve the CSV, then `d3.csvParse` to convert the text into an array of objects, and accesses `data.length` and `data.columns.length` to summarize the dataset. The data comes from a GitHub gist containing named CSS colors.

AI-generated description

parse csv data with d3

Comments

Sign in to join the discussion.

MIT Licensed