Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Fork of #Utrecht2024 TASK: First steps in Sveltenew

Public visualization

Viewing a saved revision (read-only)

699d8434aa7543a99d2bd2ae82d1c789

Fork of #Utrecht2024 TASK: First steps in Sveltenew

0 stars1🌍 Public
Kkatha.hofbauer@t-online.de
Last edited Jul 2, 2024
Created on Jul 1, 2024

This example shows a scatterplot of countries, with each country represented by a circle whose position is determined by GDP per capita on the x-axis and life expectancy on the y-axis, and whose size reflects population. The circles are colored by continent, and the data is sourced from Gapminder. The visualization maps data using `d3.scaleLinear` for the axes, `d3.scaleSqrt` for the radius, and `d3.scaleOrdinal` for the categorical color scale. It renders circles as SVG elements, with the entire plot dynamically generated in the Svelte component.

AI-generated description

Task

  • format the data: numbers should be numbers – not strings
  • filter and only use data of the year 2022
  • determine the min and max value of GDP and life expectancy

Original visualization

Interactive version

Data

Gapminder