pybraincompare.report package

Submodules

pybraincompare.report.animate module

pybraincompare.report.animate.animate_figure()[source]

Animate subplots from current matplotlib figure

pybraincompare.report.colors module

colors.py: part of pybraincompare package Color stuffs

pybraincompare.report.colors.get_colors(N, color_format='decimal')[source]

Get colors that I like

pybraincompare.report.colors.peterson_roi_labels(colors=True)[source]

Colors for Peterson ROI labels

pybraincompare.report.colors.random_colors(N)[source]

Generate N random colors

pybraincompare.report.histogram module

pybraincompare.report.image module

image.py: part of pybraincompare package Functions for static images

pybraincompare.report.image.make_anat_image(nifti_file, png_img_file=None)[source]

Make anat image

pybraincompare.report.image.make_glassbrain_image(nifti_file, png_img_file=None)[source]

Make glassbrain image, optional save image to png file (not vector)

pybraincompare.report.image.make_roi_image(nifti_file, png_img_file=None)[source]

Make roi (mask) image

pybraincompare.report.image.make_stat_image(nifti_file, png_img_file=None)[source]

Make statmap image

pybraincompare.report.image.plot_vline(cur_val, label, ax)[source]

from chrisfilo https://github.com/chrisfilo/mriqc

pybraincompare.report.qa module

qa.py: part of pybraincompare package Functions to check quality of statistical maps

pybraincompare.report.qa.central_tendency(data)[source]

Central tendency: standard measures of central tendency and variance

pybraincompare.report.qa.count_voxels(masked_in, masked_out)[source]

Count voxels in and outside the mask

pybraincompare.report.qa.get_percent_nonzero(masked_in)[source]

Estimate thresholded We basically check to see if number of zero voxels exceeds some

percentage (not thresholded)
pybraincompare.report.qa.get_voxel_range(nii_obj)[source]

Get the maximum and minimum value in the image

pybraincompare.report.qa.header_metrics(image)[source]

Metrics: Extract metrics from the header

pybraincompare.report.qa.is_only_positive(nii_obj)[source]

Are there only positive values?

pybraincompare.report.qa.is_thresholded(nii_obj, brain_mask, threshold=0.95)[source]

Is a nifti image thresholded? Adopted from chrisfilo for neurovault Threshold should be the percentage of voxels we want “good” Returns True/False and ratio of good voxels

pybraincompare.report.qa.outliers(masked_data, n_std=6)[source]

Outliers outliers (e.g., more than ~6 SD from the mean, maybe less

depending on the action)
pybraincompare.report.qa.t_to_z(mr, dof)[source]

pybraincompare.report.webreport module

Module contents