Skip to content

USCbiostats/MRIreduce

Repository files navigation

MRIreduce

USC IMAGE

Introduction

MRIreduce is an advanced R package designed to convert NIfTI format T1/FL neuroimages into structured, high-dimensional 2D data frames, focusing on region of interest (ROI) based processing. This package incorporates a key algorithm called ‘partition’, which offers a fast, flexible framework for agglomerative partitioning based on the Direct-Measure-Reduce approach. This method ensures that each reduced variable maintains a user-specified minimum level of information while being interpretable, as each maps uniquely to one variable in the reduced dataset. The ‘partition’ algorithm, detailed in Millstein et al. (2020), allows for customization in variable selection, measurement of information loss, and data reduction methods. MRIreduce is indispensable for researchers requiring efficient, accurate preparation of neuroimaging data for detailed statistical analysis and machine learning applications, enhancing the interpretability and utility of neuroimaging studies.

Installation Instructions

This document provides detailed steps to install the necessary dependencies for the package. Please follow the instructions carefully to ensure all dependencies are correctly installed.

Step 1: Install devtools

The devtools package is essential for installing packages directly from GitHub. If you do not have devtools installed, run the following code:

if (!requireNamespace("devtools", quietly = TRUE))
    install.packages("devtools")

Step 2: Install ANTsR

ANTsR is a critical package for medical image analysis in R. Install it using devtools with the following command:

devtools::install_github('ANTsX/ANTsR')

Step 3: Install fslr

The fslr package is an interface to the FSL (FMRIB Software Library) tools. Install it from GitHub:

devtools::install_github("muschellij2/fslr")

Step 4: Install EveTemplate

The EveTemplate package can be installed using remotes. First, ensure that remotes is installed:

if (!requireNamespace("remotes", quietly = TRUE))
    install.packages("remotes")

Then install EveTemplate:

remotes::install_github("neuroconductor/EveTemplate")

Step 5: Install extrantsr

extrantsr is another package essential for neuroimaging data analysis. Install it using:

devtools::install_github("muschellij2/extrantsr")

Step 6: Install FSL

FSL is not an R package but a standalone software suite for MRI and fMRI analysis. Follow the instructions on [their website] (https://fsl.fmrib.ox.ac.uk/fsl/docs/#/install/index) to download and install it.