{"version":"1.0","type":"rich","title":"The Margin Convention","description":"This example visualizes the top 10 countries by population in 2020 as horizontal bars. The chart uses the margin convention, arranging a 960 by 500 pixel SVG with a 20-pixel margin on each side. The code loads data from a CSV file using D3's `csv` utility, and then uses React state to manage the data asynchronously. Key D3 APIs include `scaleBand` for the categorical country axis, `scaleLinear` for the population axis, and `max` to compute the domain, with bars rendered as SVG `rect` elements within a transformed group.","provider_name":"VizHub AI Studio","provider_url":"https://vizhub.com","html":"<iframe src=\"https://vizhub.com/viz/fca9c08b3ea04cd7b43cee80b7a3b5a7?mode=embed\" width=\"960\" height=\"500\" scrolling=\"no\" frameborder=\"0\"></iframe>","width":960,"height":500,"cache_age":3600}