tasknoise | R Documentation |
Generates a Gaussian noise dataset with specified dimensions and standard deviation only when a task is performed or activation is present.
tasknoise(act.image, sigma, type=c("gaussian","rician"), vee=1)
act.image |
Array defining where and when activation is present. |
sigma |
Standard deviation of the noise. |
type |
Distribution of task-related noise. Default is gaussian. |
vee |
If |
The function generates random Gaussian noise for those voxels in the dataset that show activation. The result is a noise array with specified dimensions and desired standard deviation.
An array containing the noise.
M. Welvaert
temporalnoise
, lowfreqdrift
, physnoise
, systemnoise
, spatialnoise
d <- c(10,10,10)
sigma <- 5
nscan <- 100
act <- array(rep(0, prod(d)*nscan), dim=c(d,nscan))
act[2:4,2:4,2:4,c(20:30,40:50,60:70)] <- 1
out <- tasknoise(act, sigma)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.