Skip to main content
100%

Fork of Vega-Lite API Template

✓ Published0🌍 Public
AAlex Stulov
Last edited Jul 9, 2021
Created on Jul 9, 2021

This example visualizes automobile characteristics from the UCI Machine Learning Repository’s Auto MPG dataset. The scatter plot displays each car’s origin on the x-axis and its horsepower on the y-axis, with semi-transparent points and tooltips revealing the vehicle name. Built with the vega-lite-api, it uses vega-lite encoding functions like `vl.x().fieldN` and `vl.y().fieldQ` to map fields. The visualization pulls data via `d3.csv`, customizes axes and labels through a `config` object, and renders full-window SVG using vega-tooltip for interactive hover details.

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.

MIT Licensed

Similar vizzes