19.03.2013 Views

Bayesian Reasoning and Machine Learning

Bayesian Reasoning and Machine Learning

Bayesian Reasoning and Machine Learning

SHOW MORE
SHOW LESS

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

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

CONTENTS CONTENTS<br />

12 <strong>Bayesian</strong> Model Selection 265<br />

12.1 Comparing Models the <strong>Bayesian</strong> Way . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 265<br />

12.2 Illustrations : coin tossing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 266<br />

12.2.1 A discrete parameter space . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 266<br />

12.2.2 A continuous parameter space . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 267<br />

12.3 Occam’s Razor <strong>and</strong> <strong>Bayesian</strong> Complexity Penalisation . . . . . . . . . . . . . . . . . . . . . . 268<br />

12.4 A continuous example : curve fitting . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 271<br />

12.5 Approximating the Model Likelihood . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 272<br />

12.5.1 Laplace’s method . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 273<br />

12.5.2 Bayes information criterion (BIC) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 273<br />

12.6 <strong>Bayesian</strong> Hypothesis Testing for Outcome Analysis . . . . . . . . . . . . . . . . . . . . . . . . 274<br />

12.6.1 Outcome analysis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 274<br />

12.6.2 Hindep : model likelihood . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 275<br />

12.6.3 Hsame : model likelihood . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 276<br />

12.6.4 Dependent outcome analysis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 277<br />

12.6.5 Is classifier A better than B? . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 278<br />

12.7 Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 279<br />

12.8 Code . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 280<br />

12.9 Exercises . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 280<br />

III <strong>Machine</strong> <strong>Learning</strong> 285<br />

13 <strong>Machine</strong> <strong>Learning</strong> Concepts 289<br />

13.1 Styles of <strong>Learning</strong> . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 289<br />

13.1.1 Supervised learning . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 289<br />

13.1.2 Unsupervised learning . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 290<br />

13.1.3 Anomaly detection . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 291<br />

13.1.4 Online (sequential) learning . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 291<br />

13.1.5 Interacting with the environment . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 291<br />

13.1.6 Semi-supervised learning . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 292<br />

13.2 Supervised <strong>Learning</strong> . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 292<br />

13.2.1 Utility <strong>and</strong> Loss . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 292<br />

13.2.2 Using the empirical distribution . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 293<br />

13.2.3 <strong>Bayesian</strong> decision approach . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 296<br />

13.3 Bayes versus Empirical Decisions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 300<br />

13.4 Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 301<br />

13.5 Exercises . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 301<br />

14 Nearest Neighbour Classification 303<br />

14.1 Do As Your Neighbour Does . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 303<br />

14.2 K-Nearest Neighbours . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 304<br />

14.3 A Probabilistic Interpretation of Nearest Neighbours . . . . . . . . . . . . . . . . . . . . . . . 306<br />

14.3.1 When your nearest neighbour is far away . . . . . . . . . . . . . . . . . . . . . . . . . 307<br />

14.4 Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 307<br />

14.5 Code . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 307<br />

14.6 Exercises . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 307<br />

15 Unsupervised Linear Dimension Reduction 309<br />

15.1 High-Dimensional Spaces – Low Dimensional Manifolds . . . . . . . . . . . . . . . . . . . . . 309<br />

15.2 Principal Components Analysis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 309<br />

15.2.1 Deriving the optimal linear reconstruction . . . . . . . . . . . . . . . . . . . . . . . . . 310<br />

15.2.2 Maximum variance criterion . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 312<br />

15.2.3 PCA algorithm . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 312<br />

15.2.4 PCA <strong>and</strong> nearest neighbours classification . . . . . . . . . . . . . . . . . . . . . . . . . 314<br />

15.2.5 Comments on PCA . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 314<br />

XVI DRAFT January 9, 2013

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

Saved successfully!

Ooh no, something went wrong!