Learn R Programming

ANTsR (version 0.3.1)

compcor: Compcors the input matrix using SVD and returns the result.

Description

Compcors the input matrix using SVD and returns the result.

Usage

compcor(fmri, ncompcor = 4, variance_extreme = 0.975, mask = NA,
  useimagemath = FALSE, randomSamples = 1, returnv = FALSE,
  returnhighvarmat = FALSE, returnhighvarmatinds = FALSE,
  highvarmatinds = NA)

Arguments

fmri

input fmri image or matrix

ncompcor

n compcor vectors

variance_extreme

high variance threshold e.g 0.95 for 95 percent

mask

optional mask for image

useimagemath

use the imagemath implementation instead

randomSamples

take this many random samples to speed things up

returnv

return the spatial vectors

returnhighvarmat

bool to return the high variance matrix

returnhighvarmatinds

bool to return the high variance matrix indices

highvarmatinds

index list

Value

dataframe of nuisance predictors is output

Examples

Run this code
# NOT RUN {
mat <- matrix( rnorm(50000) ,ncol=500)
compcorrdf<-compcor( mat )
# }

Run the code above in your browser using DataLab