Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Fork of Dot Plot Chart of P5 CSV Loader in CS 360

Public visualization

Fork of Dot Plot Chart of P5 CSV Loader in CS 360

0 stars1🌍 Public
Hhxu51@usfca.edu
Last edited Feb 4, 2025
Created on Feb 4, 2025

This example visualizes car data from a CSV file, plotting each vehicle as a dot based on its weight (logarithmic scale on the x-axis) and fuel economy (linear scale on the y-axis). The p5.js sketch loads the data using `loadTable` in `preload()`, calculates column minimums and maximums, and renders interactive dots with tooltips showing car name, weight, and MPG on hover. Grid lines and axis labels are drawn manually. The code uses `map()` and a custom `mapLog()` function for coordinate scaling, and `createCanvas()` for a 900×700 pixel display.

AI-generated description

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

See also React Starter.

Comments

Sign in to join the discussion.

MIT Licensed