Skip to main content
100%

Pseudo Line Chart

✓ Published1🌍 Public
Ssjpeno@wpi.edu
Last edited Sep 25, 2024
Created on Sep 25, 2024

This pseudo line chart displays two data series—pink and blue—as unconnected, path-based line approximations within an SVG canvas. Rather than using scales or axes, it plots raw coordinates directly. The example demonstrates SVG Path elements and styling attributes like `fill`, `stroke`, and `stroke-width`. The code employs D3.js version 7.8.5, specifically the `d3.line` generator, to create the path data, along with `select` for DOM manipulation. Axis labels for "Unemployment Rate" and "Year" are manually positioned.

AI-generated description

An approximation of a line chart using D3.js!

Watch the video and study the code to learn about:

  • SVG Path Elements
  • fill, stroke, stroke-width
  • stroke-linecap, stroke-linejoin
  • Vanilla HTML SVG Paths
  • D3.line
  • AI Assist

See also:

Full Playlist: Constructing Visualizations

MIT Licensed

Similar vizzes