Skip to main content
100%

80. D3 Click

✓ Published0🌍 Public
Aamakanju@nyit.edu
Last edited Feb 23, 2026
Created on Feb 23, 2026

A bar chart displays a dataset of 20 numeric values, rendered as blue SVG rectangles with white value labels. Each bar darkens as its value increases. When a user clicks any bar, the corresponding data value is logged to the browser's developer console. The visualization uses D3 v4.5.0, employing `d3.scaleBand` and `d3.scaleLinear` for positioning and height, with the click event handled via `.on("click", ...)`. The y-axis is implied through bar heights that grow from the bottom, and the chart is static apart from the logging interaction.

AI-generated description
MIT Licensed

Similar vizzes