krishna Miyapuram wrote:
> I was wondering how to calculate the minimum image
> using imcalc. It doesn't appear to have
> 'min(i1,i2,i3,i4)' function in spm2.
Hi Krishna,
You're right that you can't use min like that. The solution is to use
imcalc's data matrix flag (dmtx) and simply min(X). For example:
spm_imcalc_ui(ims, 'min.img', 'min(X)', {1});
should do the trick.
Best,
Ged.
P.S. For the curious: min(5,4) is accepted by Matlab and equivalent to
min([5;4]) but only two arguments are allowed -- min(5,4,3) doesn't
work, while min([5;4;3]) does.
|