Skip to main content
100%

D3: Removing values from a chart

✓ Published0🌍 Public
深深度碎片
Last edited Aug 2, 2016
Created on Aug 2, 2016

A bar chart displays 20 numeric values, each labeled with its value. Clicking the text prompt removes the first data point and smoothly slides the remaining bars and labels left into their new positions. The example uses D3 v4’s `scaleBand` and `scaleLinear` for axes, and relies on selection `enter`, `merge`, and `exit` transitions to animate rectangles and text over 500 milliseconds. It binds data with a custom key function and renders entirely as SVG.

AI-generated description

Built with blockbuilder.org

gpl-3.0 Licensed

Similar vizzes