Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Vega-Lite API_Car

Public visualization

Viewing a saved revision (read-only)

1e1f8a1aeb7343afb927030866d2f8fd

Vega-Lite API_Car

0 stars0🌍 Public
SSkye Chen
Last edited Oct 25, 2022
Created on Oct 25, 2022

This interactive scatter plot explores automobile fuel efficiency and performance using the UCI Machine Learning Repository's Auto MPG dataset. It displays miles per gallon against horsepower, with circles sized by vehicle weight, colored by country of origin, and offering tooltips for car names. Built with the Vega-Lite API for D3, the visualization leverages `vl.markCircle`, `vl.x().fieldQ()`, and `vl.y().fieldQ()` to encode these dimensions. The code loads data via `d3.csv`, applies a custom configuration for readable axes and fonts, and renders an SVG that fills the browser window.

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.