Activity6_Task2_Qus3
This stacked bar chart displays the percentage of fruit sales across four regions: North, South, East, and West, with each bar representing a fruit type and colored segments showing regional proportions. Hovering over a segment reveals a tooltip with the exact percentage for that fruit-region combination. Built with D3 v7, the visualization uses `d3.stack()` to compute the stacked segments, `d3.scaleBand()` for the categorical y-axis, and `d3.scaleLinear()` for the percentage x-axis. The data comes from the embedded `sales.csv` file, and the SVG output includes a legend and axis labels.
AI-generated descriptionThe impact of genre on movie ratings
This stacked bar chart gives the percentage of each rating level within different movie genres. The aim is to show the impact of genre on movie ratings. When the mouse hovers over each bar, you can see pop-ups of accurate percentage of each rating level within each genre. Total percentage is 1, representing 100%.