🌍 Public
Viewing a saved revision (read-only)
29360e9da679480891e2d132b760514e
Activity-6 Q-6
This scatter plot visualizes the relationship between sweetness level and weight for four fruit types, with each fruit represented by a distinct shape and color. The visualization loads fruit data from a local CSV file and uses d3’s `csv` function to parse it, converting numeric fields. The chart is rendered using d3’s `scaleLinear` for both axes, `scaleOrdinal` for shape mapping, and `symbolsFill` for symbols. A custom shape legend, built with `symbol`, clarifies the fruit-type mapping. The axes, labels, and tick marks are generated through the `axes` module, which utilizes `axisLeft` and `axisBottom` from d3.
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.