Skip to main content
100%

Fork of Vega-Lite API Template

✓ Published0🌍 Public
TTranHBach
Last edited Jun 18, 2022
Created on Jun 18, 2022

This example builds a scatter plot of automobile data, mapping weight and horsepower along the axes and encoding the vehicle’s country of origin by color, with point size also tied to weight. It uses the Vega-Lite API (via `vl.markCircle`) to declaratively specify the visualization, which is then rendered to SVG. The underlying data is fetched as CSV using `d3.csv` from a GitHub gist, and interactivity (like tooltips) is added through the Vega Tooltip `Handler`. Custom styling is applied through a shared config object.

AI-generated description

A visualization constructed using the vega-lite-api.

MIT Licensed

Similar vizzes