Wang, I can answer: *2) Based on the xVi.h, xVi.Vi{i} and xVi.V in the SPM.mat file, I cann't acquire the equation xVi.V = xVi.h(1)*xVi.Vi{1}+ …… which is hint in spm_spm.m* The reason you cannon generate xVi.V from xVi.h and xVi.Vi as you have shown above is because spm does not do a final update of xVi.V after the xVi.hhyperparameters converge. In otherwords, the calculation of the xVi.V matrix that is actually saved to the SPM.mat file used the xVi.hhyperparameters from the iteration immediately prior to conversion. It turns out this is not much of a problem, however, as the ReML algorithm converges when the hyperparameters change by less than a very small percentage. That is, your final results will not be affected but as you have found you will not be able to generate the exact xVi.V from xVi.h and xVi.Vi. To verify this effect is negligilbe just calculate a difference matrix using your equation above and the xVi.V in SPM.mat and you'll see very small differences throughout. Best, Brian On 6/17/07, Volkmar Glauche <[log in to unmask]> wrote: > > Dear Wang Liang, > > the part of the SPM structure describing the estimated error covariance is > similar for all SPM designs, so it doesn't matter whether one looks at > first or second level statistics. The number of covariance components > estimated is just the number of elements in xVi.Vi or xVi.h. > I don't know what your second question is about... Of course, you will > only find xVi.h and xVi.V after you have estimated your model. > > Volkmar > > On Mon, 18 Jun 2007, Wang Liang wrote: > > > Dear SPMers, > > I have two questions for your help. > > 1).How to determine the number of variance components SPM provided when > > proceeding a first level statistic > > 2) Based on the xVi.h, xVi.Vi{i} and xVi.V in the SPM.mat file, I cann't > > acquire the equation xVi.V = xVi.h(1)*xVi.Vi{1}+ …… which is hint in > > spm_spm.m > > > > with best regards! > > > > wangliang > > > > -- > Volkmar Glauche > - > Department of Neurology [log in to unmask] > Universitaetsklinikum Freiburg Phone 49(0)761-270-5331 > Breisacher Str. 64 Fax 49(0)761-270-5416 > 79106 Freiburg http://fbi.uniklinik-freiburg.de/