10.07.2015 Views

Information Theory, Inference, and Learning ... - Inference Group

Information Theory, Inference, and Learning ... - Inference Group

Information Theory, Inference, and Learning ... - Inference Group

SHOW MORE
SHOW LESS
  • No tags were found...

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

Copyright Cambridge University Press 2003. On-screen viewing permitted. Printing not permitted. http://www.cambridge.org/0521642981You can buy this book for 30 pounds or $50. See http://www.inference.phy.cam.ac.uk/mackay/itila/ for links.29Monte Carlo Methods29.1 The problems to be solvedMonte Carlo methods are computational techniques that make use of r<strong>and</strong>omnumbers. The aims of Monte Carlo methods are to solve one or both of thefollowing problems.Problem 1: to generate samples {x (r) } R r=1 from a given probability distributionP (x).Problem 2: to estimate expectations of functions under this distribution, forexample∫Φ = 〈φ(x)〉 ≡ d N x P (x)φ(x). (29.3)The probability distribution P (x), which we call the target density, mightbe a distribution from statistical physics or a conditional distribution arisingin data modelling – for example, the posterior probability of a model’s parametersgiven some observed data. We will generally assume that x is anN-dimensional vector with real components x n , but we will sometimes considerdiscrete spaces also.Simple examples of functions φ(x) whose expectations we might be interestedin include the first <strong>and</strong> second moments of quantities that we wish topredict, from which we can compute means <strong>and</strong> variances; for example if somequantity t depends on x, we can find the mean <strong>and</strong> variance of t under P (x)by finding the expectations of the functions φ 1 (x) = t(x) <strong>and</strong> φ 2 (x) = (t(x)) 2 ,then usingΦ 1 ≡ E[φ 1 (x)] <strong>and</strong> Φ 2 ≡ E[φ 2 (x)], (29.4)¯t = Φ 1 <strong>and</strong> var(t) = Φ 2 − Φ 2 1 . (29.5)It is assumed that P (x) is sufficiently complex that we cannot evaluate theseexpectations by exact methods; so we are interested in Monte Carlo methods.We will concentrate on the first problem (sampling), because if we havesolved it, then we can solve the second problem by using the r<strong>and</strong>om samples{x (r) } R r=1 to give the estimatorˆΦ 1 ∑≡ φ(x (r) ). (29.6)RrIf the vectors {x (r) } R r=1 are generated from P (x) then the expectation of ˆΦ isΦ. Also, as the number of samples R increases, the variance of ˆΦ will decreaseas σ2 / R, where σ 2 is the variance of φ,∫σ 2 = d N x P (x)(φ(x) − Φ) 2 . (29.7)357

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!