{"version":"1.0","type":"rich","title":"The Margin Convention","description":"This example demonstrates the margin convention in D3 by rendering a horizontal bar chart of the top 10 most populous countries from a UN population dataset. The chart uses a React component with D3 scales (`scaleBand`, `scaleLinear`) to position and size SVG rectangles within a translated group element, explicitly reserving space via a margin object. The x-axis encodes population in 2020, while the y-axis displays country names. The code applies D3's `csv` loading and React's `useState` and `useEffect` hooks for data fetching.","provider_name":"VizHub AI Studio","provider_url":"https://vizhub.com","html":"<iframe src=\"https://vizhub.com/viz/a77224b8d2d74ed0b98404e2d7e3d711?mode=embed\" width=\"960\" height=\"500\" scrolling=\"no\" frameborder=\"0\"></iframe>","width":960,"height":500,"cache_age":3600}