Skip to main content
100%

Line chart w. gradient

✓ Published0🌍 Public
PPatrick Wojda
Last edited Mar 30, 2023
Created on Mar 30, 2023

A line chart shows Google's stock price over time, with the line colored by a red-to-blue gradient that switches sharply at the midpoint of the vertical axis. The visualization uses Vega-Lite, a high-level grammar of charts, to parse the specification and render the data from the stocks.csv source. The gradient is defined directly in the mark's color property as a linear gradient with offset stops at 0, 0.5, and 1, transitioning from red to blue. The temporal axis plots dates on the x-channel while price is mapped to the quantitative y-channel.

AI-generated description

Similar vizzes