Skip to main content
100%

Activity 6_Task 2_Tutorial

✓ Published1🌍 Public
Sshettisowmya01@gmail.com
Last edited Oct 20, 2024
Created on Oct 20, 2024
Forked from Hello VizHub

A stacked horizontal bar chart from D3 v7 visualizes the distribution of IMDb rating categories across six film genres, with each bar segment proportionally sized by a percentage from the loaded CSV data. The chart uses d3.stack() to compute layer positions, d3.scaleBand() for the categorical axis, and d3.scaleLinear() for the percentage scale. Interactive hover effects trigger a custom tooltip displaying genre-specific percentage values, while d3.axisBottom and d3.axisLeft provide labeled axes. The SVG rendering uses ordinal color mapping for rating bands and supports the documentary, drama, comedy, romance, animation, and action genres.

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.
MIT Licensed

Similar vizzes