Fork of D3-1: Making a face
✓ Published0🌍 Public
This example uses D3.js v7 to draw a simple sad face as an SVG graphic. It renders a yellow circle for the face, two blue circles for the eyes, a black quadratic curve for the mouth, and two smaller blue dots for tears, all positioned relative to the SVG’s width and height. The code uses `d3.select` to target the SVG element and chain `.append`, `.attr`, and method calls to construct the shapes. No external data is loaded; all geometric values are computed from the hardcoded dimensions.
AI-generated descriptionMIT Licensed