workflows.fmri.fsl.estimate¶
create_fixed_effects_flow()
¶
Create a fixed-effects workflow
This workflow is used to combine registered copes and varcopes across runs for an individual subject
Example¶
>>> fixedfx = create_fixed_effects_flow()
>>> fixedfx.base_dir = '.'
>>> fixedfx.inputs.inputspec.copes = [['cope1run1.nii.gz', 'cope1run2.nii.gz'], ['cope2run1.nii.gz', 'cope2run2.nii.gz']] # per contrast
>>> fixedfx.inputs.inputspec.varcopes = [['varcope1run1.nii.gz', 'varcope1run2.nii.gz'], ['varcope2run1.nii.gz', 'varcope2run2.nii.gz']] # per contrast
>>> fixedfx.inputs.inputspec.dof_files = ['dofrun1', 'dofrun2'] # per run
>>> fixedfx.run()
Inputs:
inputspec.copes : list of list of cope files (one list per contrast)
inputspec.varcopes : list of list of varcope files (one list per
contrast)
inputspec.dof_files : degrees of freedom files for each run
Outputs:
outputspec.res4d : 4d residual time series
outputspec.copes : contrast parameter estimates
outputspec.varcopes : variance of contrast parameter estimates
outputspec.zstats : z statistics of contrasts
outputspec.tstats : t statistics of contrasts
Graph¶
![digraph fixedfx{
label="fixedfx";
fixedfx_inputspec[label="inputspec (utility)"];
fixedfx_varcopemerge[label="varcopemerge (fsl)"];
fixedfx_l2model[label="l2model (fsl)"];
fixedfx_copemerge[label="copemerge (fsl)"];
fixedfx_gendofvolume[label="gendofvolume (utility)"];
fixedfx_flameo[label="flameo (fsl)"];
fixedfx_outputspec[label="outputspec (utility)"];
fixedfx_inputspec -> fixedfx_copemerge;
fixedfx_inputspec -> fixedfx_varcopemerge;
fixedfx_inputspec -> fixedfx_gendofvolume;
fixedfx_varcopemerge -> fixedfx_flameo;
fixedfx_l2model -> fixedfx_flameo;
fixedfx_l2model -> fixedfx_flameo;
fixedfx_l2model -> fixedfx_flameo;
fixedfx_copemerge -> fixedfx_gendofvolume;
fixedfx_copemerge -> fixedfx_flameo;
fixedfx_gendofvolume -> fixedfx_flameo;
fixedfx_flameo -> fixedfx_outputspec;
fixedfx_flameo -> fixedfx_outputspec;
fixedfx_flameo -> fixedfx_outputspec;
fixedfx_flameo -> fixedfx_outputspec;
fixedfx_flameo -> fixedfx_outputspec;
}](../../_images/graphviz-89d0b57ea65da1d971cdf13028758f97d8e04911.png)
create_modelfit_workflow()
¶
Create an FSL individual modelfitting workflow
Example¶
>>> modelfit = create_modelfit_workflow()
>>> modelfit.base_dir = '.'
>>> info = dict()
>>> modelfit.inputs.inputspec.session_info = info
>>> modelfit.inputs.inputspec.interscan_interval = 3.
>>> modelfit.inputs.inputspec.film_threshold = 1000
>>> modelfit.run()
Inputs:
inputspec.session_info : info generated by modelgen.SpecifyModel
inputspec.interscan_interval : interscan interval
inputspec.contrasts : list of contrasts
inputspec.film_threshold : image threshold for FILM estimation
inputspec.model_serial_correlations
inputspec.bases
Outputs:
outputspec.copes
outputspec.varcopes
outputspec.dof_file
outputspec.pfiles
outputspec.zfiles
outputspec.parameter_estimates
Graph¶
![digraph modelfit{
label="modelfit";
modelfit_inputspec[label="inputspec (utility)"];
modelfit_level1design[label="level1design (fsl)"];
modelfit_modelgen[label="modelgen (fsl)"];
modelfit_modelestimate[label="modelestimate (fsl)"];
modelfit_merge_contrasts[label="merge_contrasts (utility)"];
modelfit_ztop[label="ztop (fsl)"];
modelfit_outputspec[label="outputspec (utility)"];
modelfit_inputspec -> modelfit_level1design;
modelfit_inputspec -> modelfit_level1design;
modelfit_inputspec -> modelfit_level1design;
modelfit_inputspec -> modelfit_level1design;
modelfit_inputspec -> modelfit_level1design;
modelfit_inputspec -> modelfit_modelestimate;
modelfit_inputspec -> modelfit_modelestimate;
modelfit_level1design -> modelfit_modelgen;
modelfit_level1design -> modelfit_modelgen;
modelfit_modelgen -> modelfit_modelestimate;
modelfit_modelgen -> modelfit_modelestimate;
modelfit_modelgen -> modelfit_modelestimate;
modelfit_modelestimate -> modelfit_outputspec;
modelfit_modelestimate -> modelfit_outputspec;
modelfit_modelestimate -> modelfit_outputspec;
modelfit_modelestimate -> modelfit_outputspec;
modelfit_modelestimate -> modelfit_merge_contrasts;
modelfit_modelestimate -> modelfit_merge_contrasts;
modelfit_merge_contrasts -> modelfit_outputspec;
modelfit_merge_contrasts -> modelfit_ztop;
modelfit_ztop -> modelfit_outputspec;
}](../../_images/graphviz-49efb0d28199b5f5c0de31be2d2957ab46194f02.png)