In certain circumstances, the common methods of random number generation are inadequate to produce the desired samples. Statistics and Machine Learning Toolbox™ offers several alternative methods to generate pseudorandom and quasirandom numbers. Quasirandom numbers, also known as low discrepancy sequences, generate each successive number as far away as possible from existing numbers in the set. This approach avoids clustering and can speed up convergence, but quasirandom numbers are generally too uniform to pass randomness tests. Pseudorandom numbers are less uniform than quasirandom numbers and may be more appropriate for applications that require greater randomness. Use the slice sampler or the Metropolis-Hastings Markov chain sampler to generate pseudorandom samples by drawing from a statistical distribution.
If the available parametric probability distributions do not adequately describe your data, you can use a flexible distribution family instead. The Pearson and Johnson flexible distribution families fit a model based on the location, scale, skewness, and kurtosis of the sample data. Once you fit a distribution to your data, you can generate pseudorandom numbers from that distribution.
Quasi-random number generators (QRNGs) produce highly uniform samples of the unit hypercube.
Markov chain samplers can generate numbers from a sampling distribution that is difficult to represent directly.
The Pearson and Johnson systems are flexible parametric families of distributions that provide good matches for a wide range of data shapes.