Skip to main content
100%

Life Expectancy Slope Graph: 1960 – 2011

✓ Published0🌍 Public
PP7h
Last edited Apr 18, 2015
Created on Apr 18, 2015

A slope graph compares life expectancy at birth in 1960 and 2012 for countries worldwide, using data from the WorldBank. Each country is represented by a line connecting its two values, with labels on both ends, and the SVG is rendered using D3.js version 3. The code parses a CSV file with d3.csv, uses ordinal scales and custom collision-avoidance logic to space labels, and highlights lines and labels in red on hover via CSS classes.

AI-generated description

Similar vizzes