Skip to main content
100%

Tutorial2

✓ Published0🌍 Public
HHarshithakodakandla@my.unt.edu
Last edited Oct 23, 2024
Created on Oct 23, 2024
Forked from Hello VizHub

This stacked bar chart visualizes the distribution of movie ratings across six genres, showing the percentage of films within each rating category. The chart uses horizontal bars for each genre, segmented by rating levels from "below 5.0" to "above 8.5," with a color scale distinguishing the categories. Hovering over a segment reveals the exact percentage via a tooltip. Built with d3.v7, the visualization uses `d3.stack`, `d3.scaleBand`, and `d3.scaleLinear` to compute and render the stacked geometry, while `d3.axisBottom` and `d3.axisLeft` generate the axes, and the data is drawn as SVG rectangles.

AI-generated description

The 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%.

MIT Licensed

Similar vizzes