Activity6_Task3 question
✓ Published0🌍 Public
This example shows a scatter plot of the Palmer Penguins dataset, displaying flipper length (mm) on the x-axis and body mass (g) on the y-axis, with each point colored by species (Adelie, Gentoo, or Chinstrap). The code loads CSV data from a GitHub gist and uses D3 v7’s `d3.csv`, `d3.scaleLinear`, `d3.scaleOrdinal`, and `d3.extent` to map the values, while `d3.axisLeft` and `d3.axisBottom` add labeled axes with rotated axis titles. Circles are appended to an SVG group with a margin-based layout, and the color scale assigns distinct pastel colors to each species.
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