Skip to content

Commit 23379eb

Browse files
authored
Merge pull request #2943 from ostanley/master
[FIX] modified afni's cat_matvec to accept empty string opposed to opkey
2 parents 15a3c15 + 845463d commit 23379eb

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

nipype/interfaces/afni/utils.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -619,8 +619,9 @@ class CatMatvec(AFNICommand):
619619

620620
def _format_arg(self, name, spec, value):
621621
if name == 'in_file':
622-
return spec.argstr % (' '.join([i[0] + ' -' + i[1]
623-
for i in value]))
622+
# Concatenate a series of filenames, with optional opkeys
623+
return ' '.join('%s -%s' % (mfile, opkey) if opkey else mfile
624+
for mfile, opkey in value)
624625
return super(CatMatvec, self)._format_arg(name, spec, value)
625626

626627

0 commit comments

Comments
 (0)