This post describes how to update the X axis limit with a smooth
transition. When the button on top of the
scatter plot is updated, both the axis
and circles position are smoothly updated. See more on
scatter plot,
animation
and
buttons
if needed. This example works with d3.js v4
and
v6
updatePlot()
is created. This function rebuilds
the plot if needed for a specific X axis limit.
updatePlot()
is triggered and update the chart.