Skip to main content
100%

D3 Example 2

✓ Published1🌍 Public
OOleJRask
Last edited Aug 26, 2021
Created on Aug 25, 2021
Forked from D3 Example 1

Two datasets, `y1` and `y2`, are plotted against a shared `x` axis, showing how their values diverge over the same input range. The visualization uses a single SVG canvas with green and blue circles for each dataset, and red and black line paths connecting the points. Built with D3 v7, it loads tab-separated data from `example2.tsv` using `d3.tsv`, scales both axes with `d3.scaleLinear`, and computes the line paths with `d3.line`. The layout positions axes within a 700×400 pixel light-gray SVG.

AI-generated description
MIT Licensed

Similar vizzes