Data Visualization · Exercise 1 of 4Next
Beginner
Grow the bars
The week's bars appear at their full width at once. Make them grow from 0 to their width in 400 ms with a D3 transition.
Start the bars at width 0 and put the final width in .transition().duration(400).attr("width", ...).
What Check tests
- The code uses a transition
- The bars start at width 0
- After the transition the bars are at their final widths
- No attribute holds NaN
Stuck? One hint at a time
The solution unlocks after your first Check. Try first: that is where the learning happens.
Runs in your browser. Your code is saved here.
Your page
Press Run to see the page.
Console
Nothing logged yet.