Question3
✓ Published0🌍 Public
This example shows a scatter plot of car weight versus fuel efficiency (MPG), using a small CSV dataset with ten vehicles. Each point is colored by manufacturer, with a legend listing the distinct brands. The visualization is rendered as an SVG using D3 v6, employing `d3.csv`, `scaleLinear`, `axisLeft`, `axisBottom`, and `scaleOrdinal`. Axes are labeled for weight and MPG, with margins and a title, demonstrating basic data loading, scaling, and legend construction.
AI-generated descriptionAn example showing the capabilities of VizHub:
- Loads D3 via UNPKG.
- Demonstrates use of
importfrom"d3". - Demonstrates use of
importfrom local ES6 modules.
MIT Licensed