Skip to main content
๐ŸŒ Public

Share visualization

Send this visualization to others.

Activity6_Task2

Public visualization

Activity6_Task2

0 stars1๐ŸŒ Public
TTarshit Vupperla
Last edited Oct 23, 2024
Created on Oct 23, 2024
Forked from Hello VizHub

This example shows the distribution of IMDb movie ratings across six genres, with each genre displayed as a horizontal stacked bar chart where colored segments represent the percentage of films falling into rating brackets from "below 5.0" to "above 8.5." The visualization uses D3 v7's `d3.stack()` and `d3.scaleOrdinal()` to generate the stacked rectangles, with axes rendered via `d3.axisLeft` and `d3.axisBottom`. Interactive tooltips appear on mouseover, displaying the exact percentage for each rating segment using a formatted `d3.format` function. The data comes from a CSV file loaded directly in the HTML, with SVG as the rendering framework.

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.

Comments

Sign in to join the discussion.

MIT Licensed