Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

activity 6question 2

Public visualization

Viewing a saved revision (read-only)

3e795314633b49eb9175fa69fa4e000a

activity 6question 2

0 stars0🌍 Public
Ttsumanth619@gmail.com
Last edited Apr 4, 2024
Created on Apr 4, 2024
Forked from Hello VizHub

This stacked bar chart displays the distribution of movie ratings across five genres, segmenting each genre's total percentages into five rating ranges from "Below 5.0" to "Above 8.5". The visualization uses `d3.stack()` to aggregate the data, with `d3.scaleOrdinal` assigning distinct colors to each rating category. Horizontal bars are rendered using `d3.scaleBand` for genres and `d3.scaleLinear` for the percentage axis. Interactive tooltips, implemented with mouseover events, display the exact percentage for each rating segment when hovering, enhancing the data's readability. The chart is built with D3 v7 and rendered as SVG, using data from a CSV file.

AI-generated description

An example showing the capabilities of VizHub:

  • Loads D3 via UNPKG.
  • Demonstrates use of import from "d3".
  • Demonstrates use of import from local ES6 modules.