Tests for random numbers

In the previous sections of this chapter, random numbers have been simulated with different approaches. Most of the tests for random number generations tests if the basic random number generator, the random number generator that simulates uniformly distributed random numbers, is doing a good job.

We saw already in the beginning of the chapter plots, where we show a sequence of simulated random values against the sequence with lag 1 (and lag 2 for three-dimensional plots).

The random number generators are typically tested on whole test batteries defined by different tests. An original collection of tests can be found at http://stat.fsu.edu/pub/diehard/. These are the so-called DieHard tests from Marsaglia.

Since the code of ...

Get Simulation for Data Science with R now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.