Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Activity6_q2.1

Public visualization

Viewing a saved revision (read-only)

13c3fb9818ac4038be69d49988a6ccad

Activity6_q2.1

0 stars0🌍 Public
Ssaibharath7thota@gmail.com
Last edited Apr 14, 2024
Created on Apr 14, 2024

This stacked bar chart shows the percentage distribution of ratings for various cartoon shows, with each bar divided into five rating categories from "below 5.0" to "Above 9.0." The visualization highlights how ratings vary across shows like Ben 10, Pokémon, and Tom and Jerry, with a hover tooltip revealing exact percentages. Built with d3 v7, the chart uses `d3.stack()` to compute stacked segments, `d3.scaleLinear` for the percentage axis, and `d3.scaleBand` for the categorical genre labels. The SVG renders colored rectangles per rating segment, with mouseover events triggering a custom tooltip that displays the precise percentage per show and rating level.

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.