Skip to content

Commit

Permalink
DOC
Browse files Browse the repository at this point in the history
  • Loading branch information
gabknight committed Jan 23, 2025
1 parent fa86a0a commit 47448d5
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 5 deletions.
4 changes: 2 additions & 2 deletions scripts/scil_volume_stats_in_ROI.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@
Compute the statistics (mean, std) of scalar maps, which can represent
diffusion metrics, in ROIs. Prints the results.
The ROIs can either be a binary masks, or a weighting masks. If the ROIs are
weighting masks it should either contain floats between 0 and 1 or should be
The ROIs can either be binary masks, or weighting masks. If the ROIs are
weighting masks, they should either contain floats between 0 and 1 or should be
normalized with --normalize_weights. IMPORTANT: if the ROIs contain weights
(and not 0 and 1 exclusively), the standard deviation will also be weighted.
"""
Expand Down
7 changes: 4 additions & 3 deletions scripts/scil_volume_stats_in_labels.py
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
"""
Computes the information from the input map for each cortical region
(corresponding to an atlas).
Computes the information from the input metrics for each cortical region
(corresponding to an atlas). If more than one metric are provided, statistics are
computed separately for each.
Hint: For instance, this script could be useful if you have a seed map from a
specific bundle, to know from which regions it originated.
Expand Down Expand Up @@ -81,7 +82,7 @@ def main():
metric_data = nib.load(metric_filename).get_fdata(dtype=np.float32)
metric_name = split_name_with_nii(os.path.basename(metric_filename))[0]
if len(metric_data.shape) > 3:
parser.error('Mask should be a 3D image.')
parser.error('Input metrics should be 3D images.')

# Process
out_dict = get_stats_in_label(metric_data, label_data, label_dict)
Expand Down

0 comments on commit 47448d5

Please sign in to comment.