Skip to main content
100%

Scatter Plot Cereals

✓ Published0🌍 Public
Ppjdhungana@gmail.com
Last edited Jul 26, 2023
Created on Jul 25, 2023
Forked from Hello VizHub

A scatter plot displays the relationship between sugar and sodium content for a random selection of 35 cereals, with points colored by their overall rating. Ratings from 18-39 appear red, 40-59 orange, 60-100 green, and all others blue. The visualization loads CSV data from a GitHub gist using `d3.csv`, scales axes with `d3.scaleLinear`, and renders circles as SVG elements with `select` and `join`. Axis labels and a legend explain the color coding, while tick text is styled at 20 pixels for readability.

AI-generated description

An example showing the capabilities of VizHub:

  • Loads D3 via UNPKG.
  • Demonstrates use of import from "d3".
  • Demonstrates use of import from local ES6 modules.
MIT Licensed

Similar vizzes