Activity6_Q2
✓ Published1🌍 Public
This stacked bar chart visualizes the normalized proportions of horsepower, torque, and highway MPG for 31 car brands, showing how each metric contributes to a total value of 100% per make. The code uses d3.stack() to compute the layered segments, d3.scaleBand() for the categorical y-axis, and d3.scaleLinear() for the proportional x-axis. Data is embedded directly in the script and rendered as SVG rectangles, with a legend and percentage-formatted axis ticks.
AI-generated descriptionMIT Licensed