Pyrelimri

Latest version: v2.1.0

Safety actively analyzes 685670 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

2.1.0

Several changes and additions are made:

1. A more comprehensive docstring is used to enhance information on [PyReliMRI](https://pyrelimri.readthedocs.io/en/latest/introduction.html) readthedocs
2. The ICC function tests were expanded to confirm ICC, between subject variance and within subject variance estimates from `sumqc_icc() `are compared to estimates from liner mixed effect model outputs from stat models. Specifically, [see test](https://github.com/demidenm/PyReliMRI/blob/main/tests/test_similarity-icc.py#L12-L38) comparing pyrelimri.icc vs statsmodels
3. The returned list of estimates for ICC computations have been revised. Previously, the MSBS and MSWS were returned. However, this was not always informative to the ICC being computed, nor to understanding how variances are impacted. For example, when the ICC(3,1) was returned, the MSBS and MSWS were not directly used in the computation. Furthermore, they were not true to the denominator and the numerator for each formula. Thus, for voxelwise, edgewise, rois, etc., where `sumsq_icc()` is used, now a dictionary is returned with: 1) ICC estimate, 2) upper 95CI, 3) lower 95CI, 4) between subject variance, 5) within subject variance, 6) between measure variance (in case of ICC(2,1), otherwise None/empty values)
4. Included a TR-by-TR timeseries extraction for masks/coordinates and locked to onset times/behavioral events. This provides the extraction of the mean signal change across a timeseries for a given ROI. This is based on Nilearn's niftimaskers where standardizing via [the call 'psc'](https://github.com/nilearn/nilearn/blob/ef33ae978/nilearn/signal.py#L662C12-L663C78)
5. Included an edgewise_icc computation on correlation matrices. This is strictly for comparing a list of lists of variables includes subjects' correlation matrices across runs/sessions or the paths to these correlation matrices. Note, if using pandas dataframe standards, it is assumed that the `header = None` and `row index = None`

2.0.0

Release Notes
Release that integrates preproduction v1.1.0. Associated official zenodo and PyPI submissions.

Changes

- Integrates latest preproduction v1.1.0
- Minor documentation
- Minor citation

1.1.0

Adding ROI-based ICC calculations integrated with Nilearns datasets.

brain_icc.roi_icc(multisession_list, type_atlas, atlas_dir, icc_type = ‘icc_3’):

**REQUIRED**: multisession_list = <list of lists to >1 sessions/runs of 3D Nifti images: string (Subjects across Sessions must be in SAME order)>; atlas type = <str: ‘aal’, ‘destrieux_2009’, ‘difumo’, ‘harvard_oxford’, ‘juelich’, ‘msdl’, ‘pauli_2017’, ‘shaefer_2018’, ‘smith_2009’ or ‘talairach’>, atlas directory = <where atlas already exists or should be saved (recommend: ‘/tmp/’)>, **kwags = < additional options as required for each atlas at [Nilearn datasets](https://nilearn.github.io/dev/modules/datasets.html). Variable and value, e.g., dimension=64 can be added as instructed in the atlases documentation>
**OPTIONAL**: icc_type = <string (options include: ‘icc_3’,’icc_2’,’icc_1’). Default set to icc_3>

Function returns dictionary with 11 values:

- Atlas ROI Labels (‘roi_labels’): This contains the order of labels (e.g., pulled from atlas.labels)
- ICC estimates (‘est’): 1D array that contain ICCs estimated for N ROIs in atlas.
- ICC lower bound (lb) 95% CI (‘lowbound’): 1D array that contain lb ICCs estimated for N ROIs in atlas.
- ICC upper bound (up) 95% CI (‘upbound’): 1D array that contain ub ICCs estimated for N ROIs in atlas.
- Mean Squared Between Subject Variance (‘msbtwn’): 1D array that contain MSBS ICCs estimated for N ROIs in atlas.
- Mean Squared Within Subject Variance (‘mswthn’): 1D array that contain MSWS ICCs estimated for N ROIs in atlas.
- ICC estimates transformed back to space of ROI mask (‘est_3d’): Nifti 3D volume of ICC estimates
- ICC lower bound 95% CI transformed back to space of ROI mask (‘lowbound_3d’): Nifti 3D volume of lb ICC estimates
- ICC upper bound 95% CI transformed back to space of ROI mask (‘upbound_3d’): Nifti 3D volume of up ICC estimates
- Mean Squared Between Subject Variance transformed back to space of ROI mask (‘msbtwn_3d’): Nifti 3D volume of MSBS estimates
- Mean Squared Within Subject Variance transformed back to space of ROI mask (‘mswthn_ed’): Nifti 3D volume of MSWS estimates

1.0.1

- Bug fixes in `sumsq_icc` calculation, handling missing data. Default: mean-wise replacement, common for ICC packages = deletion
- Reduced `voxelwise_icc` redundancy
- expand `image_similarity` to include Spearman (continuous)

1.0.0

Links

Releases

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.