Weird Y axis scaling


I tried this very basic example for scatter animation (found in one of pull requests):

Initially it works fine, but if you press Randomize button 10-20 times, Y axis scales and some of scatter values won’t be shown, like that:

Any idea why it happens and how to fix it?
I would like Y axis to autoscale, not to be fixed all the time – is it possible?