SpmAnaCd - MRC CBU Imaging Wiki
CbuImaging: SpmAnaCd

Changing the location of Image files in an SPM analysis

You may often run into the problem that you ran an SPM analysis on a series of image files, and you want to repeat the analysis, but the images have now moved. The spmana_cd script is an attempt to fix this problem. It takes an SPM analysis, specified in an SPMcfg.mat, or SPM.mat, and changes the names of the image names in the analysis.Let's say your image files are now in;

/constant/network/chaos/subj1/file1.img
/constant/network/chaos/subj1/file2.img
...
/constant/network/chaos/subj2/file1.img
/constant/network/chaos/subj2/file2.img
...

But when you ran the original analysis, they were located thus:

/period/of/relative/stability/subj1/file1.img

etc.You can create a new SPM.mat file, with the path names fixed, by running

spmana_cd

from the matlab prompt.1) Choose the root directory where the files now reside, here

/constant/network/chaos

2) Choose a directory for a new (fixed) SPM.mat to go;

3) Choose the SPM.mat file containing the original analysis

Hey presto, there is a new SPM.mat file saved in the directory specified in step 2, with the path names fixed...

CbuImaging: SpmAnaCd (last edited 2013-03-07 21:23:46 by localhost)