chapter fifteen
15 Sampling continuous distributions
This chapter covers
- Special-purpose algorithms for uniform and normal distributions
- The inverse transform algorithm
- The rejection sampling algorithm
We’ve just seen how to do two important things with categorical distributions: generate random samples that conform to a desired distribution and apply Bayesian reasoning to correctly interpret how observed evidence should change our prior beliefs. In the final two chapters, we’ll look at the harder problem of doing the same two things for one-dimensional continuous distributions – random distributions of real numbers. Here, we’ll look at special-purpose techniques for sampling from particular continuous distributions; in the final chapter we’ll see how to apply Bayes’ Theorem to continuous distributions.