{"version":"1.0","type":"rich","title":"General update pattern","description":"This example demonstrates the general update pattern in D3 by visualizing a set of fruits as colored circles that change, appear, and disappear over time. The code uses `d3.selectAll` with data joins, `.enter()`, `.merge()`, and `.exit()` to handle updates, mapping fruit types to circle colors and sizes via `scaleOrdinal`. Animations are triggered by `setTimeout`, which modifies the data array and re-renders the SVG. The data is hardcoded as fruit objects, and the visualization is built with D3 v5 and SVG elements.","provider_name":"VizHub AI Studio","provider_url":"https://vizhub.com","html":"<iframe src=\"https://vizhub.com/viz/041000e7ddc3494b95c09179f84525dd?mode=embed\" width=\"960\" height=\"500\" scrolling=\"no\" frameborder=\"0\"></iframe>","width":960,"height":500,"cache_age":3600}