Create a random jitter generator function.
Jitter factor around 1.
Median value.
Jitter generator function.
Each time the returned jitter generator function is called, it returns a number within [x*(1-r), x*(1+r)] range. For example, randomJitter(0.1, 2) creates a jitter generator function that returns random values within [1.8, 2.2] range.
[x*(1-r), x*(1+r)]
randomJitter(0.1, 2)
[1.8, 2.2]
Create a random jitter generator function.