Dear Jeroen,
I think you should specify your second level model in a different way
but its estimation should nevertheless not crash the way it did so it
would be great if you could share your contrast images so that I can
reproduce the error.
That said, there are several issues with this model:
* don't include 'main effect' of factors A and B, only 'main effect' of
subject [1] and 'interaction' AxB [2 3].
* the order of factors is defined such that the one that changes slowest
is entered first so maybe enter the contrast images in the order A1B1
A1B2 A1B3 A1B4 A2B1 A2B2 A2B3 A2B4, and for the conditions matrix, use
[1 1;1 2;1 3;1 4;2 1;2 2;2 3;2 4].
* just to make sure we are talking about the same thing, SPM asks for
"Independence" in the non-sphericity options so you would enter the
opposite of what you wrote down for "dependent".
There is a wiki entry giving some examples of how to specify second
level models:
https://en.wikibooks.org/wiki/SPM/Group_Analysis
I would recommend you use the approach described there (partitioned
errors) where you will specify a different model for each question (main
effects, interaction). Doing so, you will not have to use a flexible
factorial design.
Best regards,
Guillaume.
On 24/01/18 07:12, Jeroen van Baar wrote:
> Dear SPM experts,
>
> Your advice would be appreciated on the following. I’m running into some trouble with a 2-way repeated-measures ANOVA in SPM12. I have 48 subjects and 2 within-subjects factors, factor A with 2 levels and factor B with 4 levels. I have created 8 contrast maps per subject at first level, each of which represents one of the 2x4 unique factor combinations. This means I have 8*48 = 384 scans as data in my GLM.
>
> I’ve specified a flexible factorial 2nd-level GLM as follows:
> - Factor 1: name ‘A’, dependent YES, variance EQUAL
> - Factor 2: name ‘B’, dependent YES, variance EQUAL
> - Factor 3: name ‘subject’, dependent NO, variance EQUAL
> - Each subject is added separately, with:
> o Scans: the 8 contrast maps in order A1B1-A2B1-A1B2-etc
> o Conds: [1,1;2,1;1,2;2,2;1,3;2,3;1,4;2,4]
> - Main effect for factor 1 (A): 1
> - Main effect for factor 2 (B): 2
> - Main effect for factor 3 (subject): 3
> - Interaction effect for factors 1 and 2: [1,2]
> When I attempt to estimate this model, SPM crashes after about 5 or 6 steps of the ReML estimation algorithm. Error message: ‘The requested tolerance is too high.’ Find the entire error stack below.
>
> I’ve searched this mailing list and consulted the very helpful tutorial by Glaescher & Gitelman (2008) (http://www.sbirc.ed.ac.uk/cyril/download/contrast_weighting_glascher_gitelman_2008.pdf), but can’t figure out what I did wrong. I played around with the order of the factors, putting ‘subject’ first (G&G mention this), flipping the order of factors A and B, etc, but SPM still crashed.
>
> The error message makes me think that I could solve the problem by raising the tolerance of the GLM estimation algorithm somehow, but I’m not sure if that would violate any good practice, and I wouldn’t know how to go about it either.
>
> Did I specify my model correctly? Have you encountered this error before, what might it mean, and how can I solve it?
>
> Thank you very much.
>
> Best regards,
>
> Jeroen van Baar
> PhD student @ Donders Institute, Nijmegen, The Netherlands
>
> ========================================================================
>
> SPM12: spm_est_non_sphericity (v6913) 16:21:57 - 23/01/2018
> ========================================================================
> Chunk 1/1 : ...done
> Temporal non-sphericity (9079 voxels) : ...ReML estimation
> ReML Iteration 1 : ...4.053974e+02 [+4.25]
> ReML Iteration 1 : ...4.052294e+02 [+4.75]
> ReML Iteration 1 : ...4.049247e+02 [+5.25]
> ReML Iteration 1 : ...4.043815e+02 [+5.75]
> ReML Iteration 1 : ...4.032816e+02 [+6.25]
> ReML Iteration 1 : ...4.010746e+02 [+6.75]
> ReML Iteration 1 : ...3.968957e+02 [+7.25]
> Failed 'Model estimation'
> Error using spm_dx>expv (line 279)
> The requested tolerance is too high.
> In file "/home/common/matlab/spm12/spm_dx.m" (v7144), function "expv" at line 279.
> In file "/home/common/matlab/spm12/spm_dx.m" (v7144), function "spm_dx" at line 102.
> In file "/home/common/matlab/spm12/spm_reml.m" (v7178), function "spm_reml" at line 145.
> In file "/home/common/matlab/spm12/spm_reml.m" (v7178), function "spm_reml" at line 160.
> In file "/home/common/matlab/spm12/spm_reml.m" (v7178), function "spm_reml" at line 160.
> In file "/home/common/matlab/spm12/spm_reml.m" (v7178), function "spm_reml" at line 160.
> In file "/home/common/matlab/spm12/spm_reml.m" (v7178), function "spm_reml" at line 160.
> In file "/home/common/matlab/spm12/spm_reml.m" (v7178), function "spm_reml" at line 160.
> In file "/home/common/matlab/spm12/spm_reml.m" (v7178), function "spm_reml" at line 160.
> In file "/home/common/matlab/spm12/spm_est_non_sphericity.m" (v6913), function "spm_est_non_sphericity" at line 281.
> In file "/home/common/matlab/spm12/spm_spm.m" (v7120), function "spm_spm" at line 433.
> In file "/home/common/matlab/spm12_r6470_20150506/config/spm_run_fmri_est.m" (v7057), function "spm_run_fmri_est" at line 34.
>
> The following modules did not run:
> Failed: Model estimation
>
> Error using MATLABbatch system
>
--
Guillaume Flandin, PhD
Wellcome Trust Centre for Neuroimaging
University College London
12 Queen Square
London WC1N 3BG
|