Skip to content

Commit fdee8bf

Browse files
committed
Added new lines at the end of FSL design files
1 parent 3c13c73 commit fdee8bf

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

nipype/interfaces/fsl/model.py

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1151,7 +1151,7 @@ def _run_interface(self, runtime):
11511151
for cidx in range(npoints):
11521152
mat_txt.append(' '.join(
11531153
['%e' % self.inputs.regressors[key][cidx] for key in regs]))
1154-
mat_txt = '\n'.join(mat_txt)
1154+
mat_txt = '\n'.join(mat_txt) + '\n'
11551155
# write t-con file
11561156
con_txt = []
11571157
counter = 0
@@ -1175,7 +1175,7 @@ def _run_interface(self, runtime):
11751175
convals[regs.index(reg)
11761176
] = self.inputs.contrasts[idx][3][regidx]
11771177
con_txt.append(' '.join(['%e' % val for val in convals]))
1178-
con_txt = '\n'.join(con_txt)
1178+
con_txt = '\n'.join(con_txt) + '\n'
11791179
# write f-con file
11801180
fcon_txt = ''
11811181
if nfcons:
@@ -1190,6 +1190,7 @@ def _run_interface(self, runtime):
11901190
convals[tconmap[self.inputs.contrasts.index(tcon)]] = 1
11911191
fcon_txt.append(' '.join(['%d' % val for val in convals]))
11921192
fcon_txt = '\n'.join(fcon_txt)
1193+
fcon_txt += '\n'
11931194
# write group file
11941195
grp_txt = ['/NumWaves 1',
11951196
'/NumPoints %d' % npoints,
@@ -1200,7 +1201,7 @@ def _run_interface(self, runtime):
12001201
grp_txt += ['%d' % self.inputs.groups[i]]
12011202
else:
12021203
grp_txt += ['1']
1203-
grp_txt = '\n'.join(grp_txt)
1204+
grp_txt = '\n'.join(grp_txt) + '\n'
12041205

12051206
txt = {'design.mat': mat_txt,
12061207
'design.con': con_txt,

0 commit comments

Comments
 (0)