🌍 Public
Viewing a saved revision (read-only)
9b56d6fff2284e6f8c9c529640aa07a1
Activity6_Question2
This stacked bar chart shows the percentage distribution of five rating levels across seven restaurants, using horizontally oriented bars where each segment represents a rating category. The visualization employs d3.stack() to compute stacked series from CSV data, d3.scaleBand() for the categorical y-axis, and d3.scaleLinear() for the percentage x-axis. Color encoding via d3.scaleOrdinal distinguishes rating bins, while mouseover events trigger tooltip displays showing exact percentage values. The SVG rendering includes axis labels, a title, and grid lines, with data sourced from dataQ2.csv.
AI-generated descriptionAn example showing the capabilities of VizHub:
- Loads D3 via UNPKG.
- Demonstrates use of
importfrom"d3". - Demonstrates use of
importfrom local ES6 modules.