Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Task_8_Q3

Public visualization

Task_8_Q3

0 stars1🌍 Public
DDipesh
Last edited Apr 13, 2024
Created on Apr 13, 2024

This scatter plot visualizes the relationship between customer age and family size, with points colored by gender (blue for male, red for female) from the onlinefoods dataset. The D3.js v7 code uses `d3.csv` to load remote data, `d3.scaleLinear` for both axes, and `d3.scaleOrdinal` for gender-based coloring. Circles with 0.7 opacity are positioned via `cx` and `cy` attributes, while `d3.axisBottom` and `d3.axisLeft` generate the axes, and a manual legend with circles and text labels appears in the lower right of the SVG canvas.

AI-generated description

Comments

Sign in to join the discussion.

MIT Licensed