the Volumes toolbox is integrated into the SPM8/SPM5 batch system. The
input structure of each function is created there, and the easiest
interface is through this batch system.
In the SPM8 manual (included with your distribution) you will find an
example script at the end of the "Batch system" chapter. This example is
for a standard fMRI data processing pipeline, but it would work in a
similar way for the Extract data routine of the volumes toolbox.
Alternatively, if you want to call tbxvol_extract directly, you should
save an extract batch as a .m file. You can then inspect this file to
see what structure is required. If you feed this structure directly into
tbxvol_extract, omit the top level fields up to and including the
Volumes toolbox field.
Hope this helps,
I am trying to call the Volumes toolbox in a script. Preferably, I would
like to input the SPM and the ROI variables directly to the function. I get
the below error message when using the ""tbxvol_extract"" function when
specifying only the SPM file (which I thought would open the GUI. Am I
supposed to specify something different for the input and how could I add
the ROI coordinates?