Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Fork of Fork of Vega-Lite API Template

Public visualization

Viewing a saved revision (read-only)

b2375c96188d453eabbcbeff3a491c7b

Fork of Fork of Vega-Lite API Template

0 stars0🌍 Public
Llingfa
Last edited Oct 27, 2022
Created on Oct 27, 2022

This visualization displays a scatter plot of automotive data, mapping miles per gallon and horsepower with circle size representing vehicle weight and color indicating country of origin. Built using the Vega-Lite API, the code registers both Vega and Vega-Lite libraries, then chains mark and encoding specifications programmatically. Data is loaded asynchronously from a CSV file hosted on GitHub, using d3's csv parser, and rendered as an SVG with tooltips provided by the vega-tooltip handler.

AI-generated description

A visualization constructed using the vega-lite-api.

The data shown here comes from the UCI Machine Learning Repository: Auto MPG Data Set, via Gist: Scatter Plot with Menus.