Hi Elseline,
> I´m trying to create a mean image of a set of normalized functional images
> with the spm_mean_ui script, but I´m receiving error messages (pasted
> below). I ran the script in SPM2 and SPM5, and I also tried my luck with
> Cyril Pernet´s mean_image. I tried to run the script on subsamples of the
> images, but the exact same sets of images that worked at one point rendered
> error messages the next time I selected them. I´m positive that all images
> were obtained using the same bounding box and voxel size.
The overall dimensions are not all that counts... the images may have
been reoriented or moved at some point after creation (if one was
reoriented, that's enough). Remember to quit other Matlab instances (one
error is "File locked"). Also, what software version did you use to
create the images in the first place? SPM2 may hve problems with images
from spm5, and probably vice versa. One quick thing you could try is
V = spm_vol(spm_select);
vols = spm_read_vols(V);
in spm5 (replace with spm_get in spm2). If this works, the images are at
least read into one 4D matrix in memory. From there, you can do
something like
mean_vol = mean(vols,4);
and then something like
V(1).fname = 'my_mean_image.img';
spm_write_vol(V(1),mean_vol);
Good luck :)
Marko
--
=====================================================================
Marko Wilke (Dr.med./M.D.)
[log in to unmask]
Universitäts-Kinderklinik University Children's Hospital
Abt. III (Neuropädiatrie) Dept. III (Pediatric neurology)
Hoppe-Seyler-Str. 1, D - 72076 Tübingen
Tel.: (+49) 07071 29-83416 Fax: (+49) 07071 29-5473
=====================================================================
|