🌍 Public
Viewing a saved revision (read-only)
6f7bda6ca1224b47b6fd86e48e291c3a
Activity_Task3_Question_3
This example shows a scatter plot of fifty randomly generated points, each belonging to one of three categories (A, B, or C) and plotted on a simple Cartesian grid. The visualization distinguishes categories by encoding each one with a distinct symbol—circle, cross, or diamond—and a unique color from the `d3.schemeCategory10` palette. Using D3 v7, the code creates SVG paths via `d3.symbol`, scales numeric x and y values with `d3.scaleLinear`, and adds labeled axes rendered through `d3.axisBottom` and `d3.axisLeft`.
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.