Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Week 4 Iteration

Public visualization

Viewing a saved revision (read-only)

fd2969a7051e41bd9db6aa31cc46da56

Week 4 Iteration

0 stars1🌍 Public
IIan Coolidge
Last edited Feb 8, 2024
Created on Feb 8, 2024

This scatter plot visualizes the relationship between calories and average rating for 80 different cereals. Each point's color encodes sodium content using d3.interpolateLab, transitioning from green (low sodium) to red (high sodium), revealing that high-sodium cereals tend to cluster around average calorie values rather than showing a linear trend. Users can hover over individual points to see the cereal's name through a tooltip div. The visualization uses D3.js with a linear scale for both axes and data from a CSV file.

AI-generated description

A simple scatter plot with D3 showing the 80 Cereals dataset.

This iterates on the previous version of this

In this plot, we are comparing the calories in a single serving of each cereal rounded to the nearest 10 with the average rating given to a cereal in consumer reports on a scale of 1 to 100.

Surprisingly, this plot appears to show a general trend in which the highest-rated cereals tend to be those with lower calories! In particular, the highest rated cereal in the dataset by a significant margin is All-Bran with Extra Fiber, with only 50 calories per serving. This could show that consumers value healthiness of products, or that sugary, sweet cereals might actually be less tasty to consumers than less sweet cereals!