๐ Public
Activity_8_Task-2
A stacked horizontal bar chart displays the distribution of IMDb rating ranges across six movie genres, using proportions from a CSV file. The visualization encodes genre categories on the y-axis and percentage values on the x-axis, with color-coded segments for each rating bin. Built with D3 v7, the code employs `d3.stack`, `d3.scaleOrdinal`, `d3.scaleBand`, and `d3.scaleLinear` to construct the SVG chart. Interactive tooltips appear on mouseover, showing exact percentages using `d3.format`, while hover effects adjust rectangle opacity. Axis labels and a title clarify the data.
AI-generated descriptionAn example showing the capabilities of VizHub:
- Loads D3 via UNPKG.
- Demonstrates use of
importfrom"d3". - Demonstrates use of
importfrom local ES6 modules.
MIT Licensed








Comments
Sign in to join the discussion.