🌍 Public
Viewing a saved revision (read-only)
9e13d1a9e28246fbb45cb65b2d74e7ce
Vega-Lite API Template II
This example displays a scatter plot of the auto-mpg dataset, mapping engine displacement on the x-axis and horsepower on the y-axis, with vehicle names shown via tooltips. The visualization is built entirely through the Vega-Lite API in JavaScript, using `vl.markPoint` with opacity to show data density. It loads CSV data via D3’s `csv` function, configures axis and label styling in a separate `config.js`, and renders with Vega 5 and Vega-Lite 4. The chart auto-sizes to the window and uses the Vega Tooltip handler for interactive hover details.
AI-generated descriptionA visualization constructed using the vega-lite-api.