{"version":"1.0","type":"rich","title":"D3.js - selectAll(), select(), insert(), and attr()","description":"This example demonstrates how D3.js can directly manipulate SVG elements within an HTML document. Using the D3 v7 library, the code selects all circle elements via `d3.selectAll()` and modifies their fill color and radius attributes based on their index. It then uses `d3.select('body')` followed by `insert()` to add a heading element before the SVG. The example relies entirely on D3's DOM manipulation methods—`selectAll`, `select`, `insert`, and `attr`—to modify an inline SVG containing three black circles.","provider_name":"VizHub AI Studio","provider_url":"https://vizhub.com","html":"<iframe src=\"https://vizhub.com/viz/59f22074bbed432da501d82590a297a0?mode=embed\" width=\"960\" height=\"500\" scrolling=\"no\" frameborder=\"0\"></iframe>","width":960,"height":500,"cache_age":3600}