Dear Amir, dear Peter,
Dear SPM experts,
We are using DCM for ERP to analyse age-related differences within the human motor system during a bimanual tapping task.
Here, we have fitted a full Model of 39 subjects to the data, now arranged in a GCM array, with the following spm_dcm_erp settings:
options.analysis: 'ERP'
options.spatial: 'ECD'
To review the model fit, we would like to calculate the explained variance for each subject.
Could you post the respective code to calculate the explained variance for DCM for ERP or provide us with the information where the data is stored?
Looking at the spm_dcm_fmri_check skript I assume it has to look something like this:
PSS = sum(sum(GCM{1,1}.Xy.y.^2));
RSS = sum(sum(GCM{1,1}.Xy.R.^2));
D(1) = 100*PSS/(PSS + RSS);
Thank you very much for your help!
Best regards,
Philipp
|