Skip to main content
Public

Share visualization

Loading preview…

line chart

vizhub.com

Shared links may look like this on X, LinkedIn, Slack, and Discord.

Before sharing, review the publishing checklist.

Choose how to deliver this visualization

LinkedIn caption

LinkedIn may not keep text supplied by the share sheet. Copy the caption and paste it into the post if needed. You can tag the VizHub company page when posting.

More options

Embed on a websiteCopy iframe embed code
Download & exportPNG, HTML, source ZIP

line chart

0
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

Comments

Sign in to join the discussion.

MIT Licensed