Bayesian Model Selection and Averaging SPM for MEG/EEG course Peter Zeidman 17 th May 2016, 16:15-17:00.

Slides:



Advertisements
Similar presentations
J. Daunizeau Institute of Empirical Research in Economics, Zurich, Switzerland Brain and Spine Institute, Paris, France Bayesian inference.
Advertisements

Bayesian inference Lee Harrison York Neuroimaging Centre 01 / 05 / 2009.
Hierarchical Models and
Group analysis Kherif Ferath Wellcome Trust Centre for Neuroimaging University College London SPM Course London, Oct 2010.
Bayesian models for fMRI data
Dynamic Causal Modelling for ERP/ERFs Valentina Doria Georg Kaegi Methods for Dummies 19/03/2008.
What do you need to know about DCM for ERPs/ERFs to be able to use it?
Group analyses of fMRI data Methods & models for fMRI data analysis in neuroeconomics November 2010 Klaas Enno Stephan Laboratory for Social and Neural.
MEG/EEG Inverse problem and solutions In a Bayesian Framework EEG/MEG SPM course, Bruxelles, 2011 Jérémie Mattout Lyon Neuroscience Research Centre ? ?
Classical inference and design efficiency Zurich SPM Course 2014
Bayesian models for fMRI data
Bayesian models for fMRI data Methods & models for fMRI data analysis 06 May 2009 Klaas Enno Stephan Laboratory for Social and Neural Systems Research.
J. Daunizeau Wellcome Trust Centre for Neuroimaging, London, UK Institute of Empirical Research in Economics, Zurich, Switzerland Bayesian inference.
Group analyses of fMRI data Methods & models for fMRI data analysis 28 April 2009 Klaas Enno Stephan Laboratory for Social and Neural Systems Research.
Group analyses of fMRI data Methods & models for fMRI data analysis 26 November 2008 Klaas Enno Stephan Laboratory for Social and Neural Systems Research.
2nd Level Analysis Jennifer Marchant & Tessa Dekker
Dynamic Causal Modelling (DCM): Theory Demis Hassabis & Hanneke den Ouden Thanks to Klaas Enno Stephan Functional Imaging Lab Wellcome Dept. of Imaging.
Methods for Dummies 2009 Bayes for Beginners Georgina Torbet & Raphael Kaplan.
7/16/2014Wednesday Yingying Wang
SPM Course Zurich, February 2015 Group Analyses Guillaume Flandin Wellcome Trust Centre for Neuroimaging University College London With many thanks to.
DCM for ERPs/EFPs Clare Palmer & Elina Jacobs Expert: Dimitris Pinotsis.
Group analyses of fMRI data Methods & models for fMRI data analysis November 2012 With many thanks for slides & images to: FIL Methods group, particularly.
Wellcome Dept. of Imaging Neuroscience University College London
Contrasts & Statistical Inference
Dynamic Causal Modelling Advanced Topics SPM Course (fMRI), May 2015 Peter Zeidman Wellcome Trust Centre for Neuroimaging University College London.
Dynamic Causal Modelling Introduction SPM Course (fMRI), October 2015 Peter Zeidman Wellcome Trust Centre for Neuroimaging University College London.
Ch. 5 Bayesian Treatment of Neuroimaging Data Will Penny and Karl Friston Ch. 5 Bayesian Treatment of Neuroimaging Data Will Penny and Karl Friston 18.
Bayesian Model Comparison Will Penny London-Marseille Joint Meeting, Institut de Neurosciences Cognitive de la Mediterranee, Marseille, September 28-29,
Methods for Dummies Second level Analysis (for fMRI) Chris Hardy, Alex Fellows Expert: Guillaume Flandin.
Dynamic Causal Model for evoked responses in MEG/EEG Rosalyn Moran.
Bayesian inference Lee Harrison York Neuroimaging Centre 23 / 10 / 2009.
Dynamic Causal Models Will Penny Olivier David, Karl Friston, Lee Harrison, Andrea Mechelli, Klaas Stephan Mathematics in Brain Imaging, IPAM, UCLA, USA,
Bayes for Beginners Anne-Catherine Huys M. Berk Mirza Methods for Dummies 20 th January 2016.
Bayesian Inference in SPM2 Will Penny K. Friston, J. Ashburner, J.-B. Poline, R. Henson, S. Kiebel, D. Glaser Wellcome Department of Imaging Neuroscience,
Dynamic Causal Models Will Penny Olivier David, Karl Friston, Lee Harrison, Stefan Kiebel, Andrea Mechelli, Klaas Stephan MultiModal Brain Imaging, Copenhagen,
Group Analyses Guillaume Flandin SPM Course London, October 2016
Dynamic Causal Modeling of Endogenous Fluctuations
Bayesian Inference Will Penny
SPM for M/EEG - introduction
Dynamic Causal Modelling (DCM): Theory
Group analyses Thanks to Will Penny for slides and content
Dynamic Causal Model for evoked responses in M/EEG Rosalyn Moran.
Contrasts & Statistical Inference
'Linear Hierarchical Models'
Wellcome Dept. of Imaging Neuroscience University College London
Linear Hierarchical Modelling
Group analyses Thanks to Will Penny for slides and content
SPM2: Modelling and Inference
Dynamic Causal Modelling for M/EEG
Dynamic Causal Modelling
Guillaume Flandin Wellcome Trust Centre for Neuroimaging
Hierarchical Models and
Wellcome Dept. of Imaging Neuroscience University College London
Bayesian inference J. Daunizeau
M/EEG Statistical Analysis & Source Localization
DCM for fMRI – Advanced Topics
Contrasts & Statistical Inference
Bayesian Inference in SPM2
Wellcome Centre for Neuroimaging, UCL, UK.
Mixture Models with Adaptive Spatial Priors
Dynamic Causal Modelling for evoked responses
WellcomeTrust Centre for Neuroimaging University College London
Wellcome Dept. of Imaging Neuroscience University College London
Wellcome Dept. of Imaging Neuroscience University College London
DCM Demo – Model Specification, Inversion and 2nd Level Inference
Bayesian Model Selection and Averaging
Contrasts & Statistical Inference
Group DCM analysis for cognitive & clinical studies
Presentation transcript:

Bayesian Model Selection and Averaging SPM for MEG/EEG course Peter Zeidman 17 th May 2016, 16:15-17:00

Contents DCM recap Comparing models (within subject) Bayes rule for models, Bayes Factors, odds ratios Investigating the parameters Bayesian Model Averaging Comparing models across subjects Fixed effects, random effects Parametric Empirical Bayes Based on slides by Will Penny

DCM Framework 1.We embody each of our hypotheses in a generative model. Each model differs in terms of connections that are present are absent (i.e. priors over parameters). 2.We perform model estimation (inversion) 3.We inspect the estimated parameters and / or we compare models to see which best explains the data.

Image credit: Marcin Wichary, Flickr time (Experimental inputs) Predicted data (e.g. timeseries) Our belief about each parameter is represented by a normal distribution with a mean and variance (uncertainty) We represent and estimate the full covariance matrix between parameters:

DCM recap

Contents DCM recap Comparing models (within subject) Bayes rule for models, Bayes Factors, odds ratios Investigating the parameters Bayesian Model Averaging Comparing models across subjects Fixed effects, random effects Parametric Empirical Bayes Based on slides by Will Penny

Bayes Rule for Models Question: I’ve estimated 10 DCMs for a subject. What’s the posterior probability that any given model is the best? Prior on each model Probability of each model given the data Model evidence

Bayes Factors Ratio of model evidence Note: The free energy approximates the log of the model evidence. So the log Bayes factor is: From Raftery et al. (1995)

Bayes Factors cont. Posterior probability of a model is the sigmoid function of the log Bayes factor

Log BF relative to worst model Posterior probabilities

Bayes Factors cont. If we don’t have uniform priors, we can easily compare models i and j using odds ratios: The prior odds are: The posterior odds are: The Bayes factor is still: So Bayes rule is: eg. priors odds of 2 and Bayes factor of 10 gives posterior odds of 20 “20 to 1 ON” in bookmakers’ terms

Interim summary

Dilution of evidence If we had eight different hypotheses about connectivity, we could embody each hypothesis as a DCM and compare the evidence: Problem: “dilution of evidence” Similar models share the probability mass, making it hard for any one model to stand out Models 1 to 4 have ‘top-down’ connections Models 5 to 8 have ‘bottom-up’ connections

Family analysis Grouping models into families can help. Now, one family = one hypothesis. Family 1: four “top-down” DCMs Family 2: four “bottom-up” DCMs Posterior family probability: Comparing a small number of models or a small number of families helps avoid the dilution of evidence problem

Family analysis

Contents DCM recap Comparing models (within subject) Bayes rule for models, Bayes Factors, odds ratios Investigating the parameters Bayesian Model Averaging Comparing models across subjects Fixed effects, random effects Parametric Empirical Bayes Based on slides by Will Penny

Bayesian Model Averaging (BMA) Having compared models, we can look at the parameters (connection strengths). We average over models, weighted by the model evidence. This can be limited to models within the winning family. SPM does this using sampling

Example BMA workflow 1.For each hypothesis, specify one or more DCMs (to form families) 2.Estimate all DCMs 3.Use Bayesian Model Selection to identify the winning family 4.Using Bayesian Model Averaging to average the connection strengths, using only the DCMs from the winning family

Contents DCM recap Comparing models (within subject) Bayes rule for models, Bayes Factors, odds ratios Investigating the parameters Bayesian Model Averaging Comparing models across subjects Fixed effects, random effects Parametric Empirical Bayes Based on slides by Will Penny

Fixed effects (FFX) FFX summary of the log evidence: Group Bayes Factor (GBF): Stephan et al., Neuroimage, 2009

Fixed effects (FFX) 11 out of 12 subjects favour model 1 GBF = 15 (in favour of model 2). So the FFX inference disagrees with most subjects. Stephan et al., Neuroimage, 2009

Random effects (RFX) SPM estimates a hierarchical model with variables: Expected probability of model 2 Outputs: Exceedance probability of model 2 This is a model of models Stephan et al., Neuroimage, 2009

Expected probabilities Exceedance probabilities

Contents DCM recap Comparing models (within subject) Bayes rule for models, Bayes Factors, odds ratios Investigating the parameters Bayesian Model Averaging Comparing models across subjects Fixed effects, random effects Parametric Empirical Bayes Based on slides by Will Penny

Hierarchical model of parameters First level DCM Image credit: Wilson Joseph from Noun Project Group Mean Disease

Hierarchical model of parameters Second level (linear) model Priors on second level parameters Parametric Empirical Bayes Between-subject error DCM for subject i Measurement noise First level Second level Image credit: Wilson Joseph from Noun Project

Hierarchical model of parameters Matrix of DCM connections Within-subjects (W) Connection X (1)  K PEB Parameter Connection Design matrix (covariates) Between-subjects (X) Covariate Subject

subjects models PEB spm_dcm_peb Applications: Get improved first level DCM estimates Compare specific nested models (switch off combinations of connections) Search over nested models Prediction (leave-one-out cross validation) GCM_XX.mat First Level DCMs

Summary We can compare models within a subject using the Bayes Factor We can compare models at the group level using the Group Bayes Factor (fixed effects) or a hierarchical model of models (random effects) We can test for between-groups differences in connection strengths using a hierarchical model over parameters (the new PEB framework)

Further reading Overview: Stephan, K.E., Penny, W.D., Moran, R.J., den Ouden, H.E., Daunizeau, J. and Friston, K.J., Ten simple rules for dynamic causal modeling. NeuroImage, 49(4), pp Free energy: Penny, W.D., Comparing dynamic causal models using AIC, BIC and free energy. Neuroimage, 59(1), pp Random effects model: Stephan, K.E., Penny, W.D., Daunizeau, J., Moran, R.J. and Friston, K.J., Bayesian model selection for group studies. NeuroImage, 46(4), pp Parametric Empirical Bayes (PEB): Friston, K.J., Litvak, V., Oswal, A., Razi, A., Stephan, K.E., van Wijk, B.C., Ziegler, G. and Zeidman, P., Bayesian model reduction and empirical Bayes for group (DCM) studies. NeuroImage. Thanks to Will Penny for his lecture notes on which these slides are based.