Skip to content

Commit a166a76

Browse files
committed
fixed docstrings, added doctests
1 parent 36a7f05 commit a166a76

File tree

1 file changed

+24
-2
lines changed

1 file changed

+24
-2
lines changed

nipype/workflows/dmri/fsl/artifacts.py

Lines changed: 24 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -204,6 +204,17 @@ def all_fsl_pipeline(name='fsl_all_correct',
204204
*DWI* [Jones10]_.
205205
206206
207+
Examples
208+
--------
209+
210+
>>> from nipype.workflows.dmri.fsl.artifacts import all_fsl_pipeline
211+
>>> allcorr = all_fsl_pipeline()
212+
>>> allcorr.inputs.inputnode.in_file = 'epi.nii'
213+
>>> allcorr.inputs.inputnode.alt_file = 'epi_rev.nii'
214+
>>> allcorr.inputs.inputnode.in_bval = 'diffusion.bval'
215+
>>> allcorr.inputs.inputnode.in_bvec = 'diffusion.bvec'
216+
>>> allcorr.run() # doctest: +SKIP
217+
207218
"""
208219

209220
inputnode = pe.Node(niu.IdentityInterface(fields=['in_file', 'in_bvec',
@@ -285,7 +296,7 @@ def hmc_pipeline(name='motion_correct'):
285296
can be chained.
286297
This is useful to correct for artifacts with only one interpolation process
287298
(as previously discussed `here
288-
<https://github.com/nipy/nipype/pull/530#issuecomment-14505042>`_),
299+
<https://github.com/nipy/nipype/pull/530#issuecomment-14505042>`_),
289300
and also to compute nuisance regressors as proposed by [Yendiki13]_.
290301
291302
.. warning:: This workflow rotates the `b`-vectors, so please be advised
@@ -657,7 +668,7 @@ def sdc_peb(name='peb_correction',
657668
(e.g. *A>>>P* and *P>>>A*, or equivalently, *-y* and *y*)
658669
as in [Chiou2000]_, but it is also possible to use orthogonal
659670
configurations [Cordes2000]_ (e.g. *A>>>P* and *L>>>R*,
660-
or equivalently *-y* and *x*).
671+
or equivalently *-y* and *x*).
661672
This workflow uses the implementation of FSL
662673
(`TOPUP <http://fsl.fmrib.ox.ac.uk/fsl/fslwiki/TOPUP>`_).
663674
@@ -756,6 +767,17 @@ def remove_bias(name='bias_correct'):
756767
<http://dx.doi.org/10.1016/j.neuroimage.2014.07.061>`_. NeuroImage (2014).
757768
doi: 10.1016/j.neuroimage.2014.07.061
758769
770+
771+
Example
772+
-------
773+
774+
>>> from nipype.workflows.dmri.fsl.artifacts import remove_bias
775+
>>> bias = remove_bias()
776+
>>> bias.inputs.inputnode.in_file = 'epi.nii'
777+
>>> bias.inputs.inputnode.in_bval = 'diffusion.bval'
778+
>>> bias.inputs.inputnode.in_mask = 'mask.nii'
779+
>>> bias.run() # doctest: +SKIP
780+
759781
"""
760782
inputnode = pe.Node(niu.IdentityInterface(fields=['in_file', 'in_bval',
761783
'in_mask']), name='inputnode')

0 commit comments

Comments
 (0)