Skip to main content
Public

Share visualization

Loading preview…

D3-LineChart

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

D3-LineChart

1
CChandana Srinivas
Last edited Feb 26, 2024
Created on Feb 25, 2024
Forked from HTML Starter

This example shows a line chart tracking the average population of the Iris-Setosa species from 2017 to 2023, with data points marked by circles that enlarge and display a red tooltip on mouseover. The visualization is built using D3 v7 within a React-compatible HTML page, rendering to an SVG canvas. It employs d3.line to construct the path, d3.scaleLinear for both axes, d3.axisBottom and d3.axisLeft for tick marks, and d3.csv to load external data from a GitHub gist. The chart uses a steelblue stroke and the d3.schemeBuPu color scheme for points and line.

AI-generated description

A bare minimum HTML page demonstrating use of CSS and JavaScript.

See also React Starter.

Comments

Sign in to join the discussion.

MIT Licensed