Skip to main content
100%

Loading and parsing CSV Data

✓ Published0🌍 Public
DDeborahVdeV
Last edited Mar 16, 2021
Created on Mar 11, 2021
Forked from HTML Starter

This example displays basic metrics about a CSV file loaded from a Google Sheets URL, presenting the data size in kilobytes, row count, and column count as plain text on a webpage. It demonstrates asynchronous data loading and parsing using the `d3.csv` method, which fetches the remote spreadsheet and converts it into an array of objects. The code then computes the formatted string length with `d3.csvFormat`, accesses `data.length` for rows, and uses `data.columns.length` to count columns, writing the result into a DOM element via `textContent`.

AI-generated description

A bare minimum HTML page demonstrating use of CSS and JavaScript.

See also React Starter.

MIT Licensed

Similar vizzes