Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Let's Make a Face with D3.js

Public visualization

Viewing a saved revision (read-only)

f5a1fb1c7a0a499f8e259b5dca76d438

Let's Make a Face with D3.js

0 stars3🌍 Public
Ddanrhymes
Last edited Nov 29, 2019
Created on Nov 29, 2019

This example illustrates how to construct a cartoon face using basic D3.js shape primitives. It renders a yellow circular head with black stroke, two eyes, and a smiling mouth as a path generated by the `d3.arc()` generator. The code selects an SVG element and uses `d3.select` to append groups and circles, positioning them via `translate` transforms. The mouth arc uses fixed inner and outer radii with defined start and end angles, demonstrating a composable approach to SVG drawing with D3 v5.

AI-generated description