-
Notifications
You must be signed in to change notification settings - Fork 536
Closed
Description
'write_which' is currently defined as follows:
write_which = traits.Tuple(traits.Int, traits.Int, field='roptions.which',
desc='determines which images to reslice')
This generates the following in pyscript_realign.m:
jobs{1}.spatial{1}.realign{1}.estwrite.roptions.which = (0, 1);
That is not valid matlab syntax - it causes the following type of error:
Error: Expression or statement is incorrect--possibly unbalanced (, {, or [.
I launched matlab and built a job by hand. 'which' is supposed to be a two item vecor, like so:
>> matlabbatch{1}.spm.spatial.realign.estwrite.roptions
ans =
which: [0 1]
interp: 4
wrap: [0 0 0]
mask: 1
prefix: 'r'
If I redefine write_which like so:
write_which = traits.List(traits.Int, traits.Int, field='roptions.which',
desc='determines which images to reslice')
... it generates the following matlab script:
jobs{1}.spatial{1}.realign{1}.estwrite.roptions.which(1) = 0;
jobs{1}.spatial{1}.realign{1}.estwrite.roptions.which(2) = 1;
... which works.
I will submit a pull request for this shortly.
Metadata
Metadata
Assignees
Labels
No labels