Fork of Vega-Lite API Template
✓ Published0🌍 Public
This example uses the Vega-Lite API to render a scatter plot of Auto MPG data from the UCI Machine Learning Repository, loaded via `d3.csv`. The visualization encodes miles per gallon (mpg) on the x-axis and horsepower on the y-axis as quantitative fields, with color mapped to the categorical origin of each vehicle. Point size represents weight, and tooltips display model names using `vl.tooltip()`. The chart is built programmatically in `viz.js` and rendered with an SVG view, customized through a shared `config.js` for improved label and title readability.
AI-generated descriptionA 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