Rejection sampling

An algorithm to sample from a distribution

Assumptions:

  • Need a bounding distribution that you can sample from easily
  • The ratio of the functions is bounded, so
  • Define

Algorithm

  1. Generate some realization y from
  2. Find
  3. Sample from
  4. If , accept If , reject

The - they are realizations of f


References

Simulating distribution @rice2007 @lancaster2004 - Chapter 5