Skip to content

Commit 5245402

Browse files
author
David Ellis
committed
ENH: Adds the MakeAverage to the example recon-all workflow.
1 parent 87c9ed3 commit 5245402

File tree

1 file changed

+13
-1
lines changed

1 file changed

+13
-1
lines changed

examples/smri_fsreconall.py

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
#!/usr/bin/env python
22
"""
33
================
4-
sMRI: FreeSurfer
4+
sMRI: FSReconAll
55
================
66
77
This script, smri_fsreconall.py, demonstrates the ability to use the
@@ -75,4 +75,16 @@
7575
wf.connect(datasource, 'struct', recon_all, 'inputspec.T1_files')
7676
wf.connect(inputspec, 'subject_id', recon_all, 'inputspec.subject_id')
7777

78+
"""
79+
Make average subject
80+
"""
81+
82+
average = pe.JoinNode(interface=MakeAverageSubject(),
83+
joinsource="inputspec",
84+
joinfield="subjects_ids",
85+
name="average")
86+
average.inputs.subjects_dir = subjects_dir
87+
88+
wf.connect(recon_all, 'postdatasink_outputspec.subject_id', average, 'subjects_ids')
89+
7890
wf.run("MultiProc", plugin_args={'n_procs': 4})

0 commit comments

Comments
 (0)