fMRIscrub is a collection of routines for data-driven
scrubbing (projection scrubbing and DVARS), motion scrubbing, and other
fMRI denoising strategies such as anatomical CompCor, detrending, and
nuisance regression. Projection scrubbing is also applicable to other
outlier detection tasks involving high-dimensional data.
This package builds off of fMRItools,
which collects common functions for handling fMRI data, and ciftiTools
to support working with the CIFTI format. Also check out our new
package, rrobot, for
methods made for robust outlier detection.
You can install the development version of fMRIscrub from CRAN with:
install.packages("fMRIscrub")s_Dat1 <- IDvols(Dat1)
plot(s_Dat1)
Dat1_cleaned <- Dat1[!s_Dat1$outlier_flag,]Two scans from the ABIDE
I are included in fMRIscrub: Dat1 has many
artifacts whereas Dat2 has few visible artifacts. Both are
vectorized sagittal slices stored as numeric matrices. They are loaded
into the environment upon loading the package.
We acknowledge the corresponding funding for the ABIDE I data:
Primary support for the work by Adriana Di Martino was provided by the (NIMH K23MH087770) and the Leon Levy Foundation. Primary support for the work by Michael P. Milham and the INDI team was provided by gifts from Joseph P. Healy and the Stavros Niarchos Foundation to the Child Mind Institute, as well as by an NIMH award to MPM ( NIMH R03MH096321).
See this link to view the tutorial vignette.
If using projection scrubbing, you can cite our 2023 paper “Less is more: balancing noise reduction and data retention in fMRI with data-driven scrubbing”. In the Methods section there is also a description of how FD and DVARS are calculated (section 2.2), and how scrubbing can be implemented in a simultaneous nuisance regression framework (section 2.3.3).