Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

line chart

Public visualization

Viewing a saved revision (read-only)

30ea3b03a10c42b5987967c3b94e8197

line chart

0 stars0🌍 Public
Sshreelasya.bezawada@gmail.com
Last edited Oct 27, 2025
Created on Oct 27, 2025
Forked from HTML Starter

This line chart shows the relationship between population and electricity consumption across major global cities, with each point representing a city and a smooth curve connecting them by ascending population. The visualization uses D3 v7 with SVG rendering and includes interactive hover tooltips displaying detailed city statistics. Data is loaded from a remote text file, parsed in-browser using `d3.csvParse`, then sorted and scaled with `d3.scaleLinear`. The chart applies `d3.axisBottom` and `d3.axisLeft` for axes, `d3.line` with `curveMonotoneX` for the path, and gridlines generated from the axis scales.

AI-generated description