Body size pipeline

This pipeline extends the original Analysis pipeline and assesses the influence of body size on the structure of the central nervous system. All prerequisities and methods described for the Analysis pipeline applies even here with additional required dependencies and methods as described bellow.

This pipeline has been available since the source code release RXYZXXXX (to be edited) and presented in:

Labounek et al. (2022) Body size influences the structure of the central nervous system: a multi-center in vivo human neuroimaging study [Under Review]




  • FSLeyes for correcting segmentations.
  • FreeSurfer >=7.2 for segmentation and assessmnet of cerebral morphology from the T1 scan.

Spinal cord image analysis

The same methods as used in the Analysis pipeline, i.e sub-sections Getting started and Quality Control.

Cerebral image analysis

You need to proceed your own automated cerebral segmentation of T1 scans through the FreeSurfer >=7.2 software or download values obtained by the UMN MILab, which visually inspected and corrected (if necessary) all segmentation outcomes prior to extraction of the quantitative measurements.

Where to download UMN MILab measurements?

git clone
cd spine-generic-body-size-results
cp fs_measurements.xlsx sg.*.aparc.stats.*.csv <PATH_RESULTS>

Your own FreeSurfer segmentation and measurements

  • Group brain_t1 in the exclude.yml file defines list of scans whose cerebral volumes are not possible to be segmented correctly due to listed reasons.
  • You need to build your own fs_measurements.xlsx table.
  • The bash script can help you to automatically export the sg.*.aparc.stats.*.csv files.
  • Store all table files in the <PATH_RESULTS> folder.

Generate figures

  • Make a copy and re-edit the spine-generic/matlab/sg_example_script.m regarding to your own HDD.
  • Open MATLAB >= R2017b (>= R2021b recomended due to automated axis label orientations)
  • Execute re-edited script or execute following commands with a variable setting fitting your HDD
% path to the YAMLMatlab 0.4.3 toolbox
path_yamltoolbox = '/home/user/toolbox/matlab/YAMLMatlab_0.4.3';
% path to the spine-generic source code
path_spinegeneric = '/home/user/git/spine-generic';
% path to the <PATH_RESULTS> folder
path_results = '/home/user/spine-generic/data-multi-subject_results';
% path to the <PATH_DATA> folder
path_data = '/home/user/spine-generic/data-multi-subject';
% Execute
stat = sg_structure_versus_demography(path_results,path_data);
% Figures exported in fig_*.png format and stat_labounek2022.mat file
% will appear in the <PATH_RESULTS> folder


(to be extended once the whole dataset is analyzed)