| Thank you John for your previous answer. Another question regarding the
| estimation of a design with data for VBM bothers me.
| As we use smoothed and binarized data I wonder what the scaling function
| for removing global effects precisely does in this case and if it is
| necessary.
| Any comment or hint (on literature) will be appreciated!
The function for computing "globals" is not ideal for VBM data. A better
"global" would be based on the total amount of grey matter in the image.
The following function should do the job nicely. Alternatively, you may wish
to normalise to whole brain volume, by adding the integrals of grey and
white matter, or cranial volume by including CSF.
It all depends on what you are looking for. Researchers into dementia
generally normalise to cranial volume in order to get some idea of brain
shrinkage.
Best regards,
-John
_______________________cut below here______________________________________
function gl = get_integrals(P)
% Integrate the values in an image.
if nargin<1,
P = spm_get(Inf,'*.img');
end;
V = spm_vol(P);
gl = zeros(length(V),1);
for i=1:length(gl),
for z=1:V(i).dim(3),
img = spm_slice_vol(V(i),spm_matrix([0 0 z]),V(i).dim(1:2),0);
gl(i) = gl(i) + sum(img(:));
fprintf('.');
end;
fprintf('\n');
end;
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
|