Fork of Vega-Lite API Template
This example visualizes the Auto MPG dataset from the UCI Machine Learning Repository, plotting miles per gallon against horsepower with circles colored by origin and sized by weight. Tooltips reveal additional attributes like vehicle name, cylinders, and acceleration. The visualization is built using the Vega-Lite API, which wraps Vega-Lite specifications in a fluent JavaScript interface, and renders via D3.js (v5) with dynamic width and height fitted to the browser window. Appearance is customized through a central config object that adjusts axis styles and label typography.
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.