Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

A simple Bar Chart

Public visualization

Viewing a saved revision (read-only)

b84c32a191a54f8fbed35a959e0aa334

A simple Bar Chart

0 stars0🌍 Public
KKaustav Sen
Last edited May 31, 2021
Created on May 26, 2021
Forked from HTML Starter

A simple bar chart displays a dataset of numeric values as vertical bars, with each bar labeled by its value. The chart updates dynamically when the user clicks text prompts to add or remove a data point, animating the bars and labels to reflect the new data. Built with D3 v6, the visualization uses `scaleBand` and `scaleLinear` for scaling, `transition` for smooth animations, and SVG `rect` and `text` elements for rendering. The initial data is hardcoded in the script, and new values are randomly generated.

AI-generated description

A Simple Bar Chart