Activity6_tak2.1
This stacked bar chart visualizes product sales across three categories, with each bar segment representing a product's sales contribution. The chart uses horizontal bars, with colors differentiating categories and a legend identifying each one. The visualization is rendered as an SVG using D3.js v7, employing the `d3.stack()` function to compose the stacked data structure, `d3.scaleLinear()` and `d3.scaleBand()` to set the scales, and `d3.scaleOrdinal()` for color encoding. Mouseover events log category sales amounts to the console, providing an interactive element.
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%.