Bowl of Fruit - General Update Pattern
✓ Published0🌍 Public
This example demonstrates the general update pattern in D3, showing how circles representing fruit change over time as data is modified. The visualization renders five apples as red circles using `d3.scaleOrdinal` for both color and radius, then removes one fruit after a second and changes another from apple to lemon after two seconds. The code uses D3's data join with `selection.enter`, `selection.merge`, and `selection.exit` to handle updating, entering, and exiting SVG circle elements.
AI-generated descriptionMIT Licensed