We will now proceed to examine another approach to perform approximate inference.
In sampling-based methods, we use samples drawn from the distribution to estimate statistics from the overall distribution. The samples drawn are independent and identically distributed.
In the chapter on parameter estimation, we have drawn samples from the posterior distribution to estimate the probabilities of a CPD using methods such as maximum likelihood and Bayesian approaches.
In this section, we will learn to sample from a Bayesian network, which is slightly different from sampling a distribution.
A sampling method that uses the topological ordering of a Bayes network is called forward sampling. A topological ordering in ...