Skip to main content
100%

activity6_question6

✓ Published1🌍 Public
MMili Patel
Last edited Mar 30, 2025
Created on Mar 30, 2025

This scatterplot shows the relationship between GDP per capita and life expectancy across ten countries, with each point colored by continent and revealing a general trend where higher GDP aligns with longer lifespans. Built with D3 v7, the visualization uses `d3.scaleLinear` for both axes and `d3.scaleOrdinal` with `d3.schemeSet2` for continent colors. Data is loaded from `data.csv` via `d3.csv`, and interactive tooltips appear on hover using the `mousemove` event, displaying country name, GDP, and life expectancy.

AI-generated description
MIT Licensed

Similar vizzes