Wrapper to CompCor for HCP data. Can perform CompCor on a data ROI from the same fMRI volume as the one containing the noise ROIs, or on a separate CIFTI file.

CompCor.HCP(
  vol,
  labs = NULL,
  data_labs = NULL,
  data_cii = NULL,
  noise_ROI = NULL,
  noise_nPC = 5,
  noise_erosion = 0,
  verbose = TRUE
)

Arguments

vol

The \(I x J x K x T\) volumetric fMRI timeseries, including both the data voxels (unless data_cii is provided) and the noise voxels. In the HCP, the corresponding file is e.g. "Results/rfMRI_REST1_LR/rfMRI_REST1_LR.nii.gz". Can also be the file path to this NIFTI.

labs

The \(I x J x K\) labels. Values should be according to this table: https://surfer.nmr.mgh.harvard.edu/fswiki/FsTutorial/AnatomicalROI/FreeSurferColorLUT . In the HCP, the corresponding file is "ROIs/Atlas_wmparc.2.nii.gz". Can also be the file path to this NIFTI.

data_labs

Numeric vector of labels that make up the data ROI. If NULL (default), use these:

do.call(c, list(cortex=c(1000:2035), subcort=c(8, 10, 11, 12, 13, 16, 17, 18, 26, 28, 47, 49, 50, 51, 52, 53, 54, 58, 60)))

Alternatively, this can be "cortex" to use the default labels corresponding to the cortical grey matter, or "subcort" to use the default labels corresponding the the subcortical grey matter.

If data_cii is provided data_labs is ignored.

data_cii

"cifti" object from which the noise ROI components will be regressed. If data_cii is provided data_labs is ignored.

noise_ROI

List of numeric vectors, where each entry contains the label values in labs corresponding to a noise ROI e.g. the white matter (WM) or cerebrospinal fluid (CSF). If NULL (default), use these:

list(wm_cort = c(3000:4035, 5001, 5002), csf = c(4, 5, 14, 15, 24, 31, 43, 44, 63, 250, 251, 252, 253, 254, 255))

These default ROIs are based on this forum post: https://www.mail-archive.com/hcp-users@humanconnectome.org/msg00931.html

Alternatively, this can be "wm_cort" to use the default entry corresponding to cortical white matter, or "csf" to use the default entry corresponding to the CSF.

noise_nPC, noise_erosion

See CompCor

verbose

Print occasional updates? Default: TRUE.

Value

A list with entries "data" and "noise". If !is.null(data_labs), "data" will be a \(V x T\) data matrix where each row is a voxel time series from which the noise components have been regressed (voxels in spatial order, and only voxels in the data ROI are included). Otherwise, if !is.null(data_cii), it will be the same "cifti" object but with the noise components regressed from each brainordinate.

The entry "noise" is a list of T \(x\) noise_nPC PC scores, one for each noise_ROI.