Last data update: 2014.03.03

R: Generate temporally correlated noise
temporalnoiseR Documentation

Generate temporally correlated noise

Description

Generates an autoregressive noise dataset with specified dimensions and standard deviation.

Usage

temporalnoise(dim, nscan, sigma, rho = 0.2, template, verbose = TRUE)

Arguments

dim

A vector specifying the dimensions of a 2D or 3D array.

nscan

The number of scans in the dataset.

sigma

The standard deviation of the noise.

rho

The autocorrelation coefficients. The length of the vector determines the order of the autoregressive model.

template

An array representing the anatomical structure or mask with dimensions equal to dim.

verbose

Logical indicating if warnings should be printed.

Value

An array containing the noise with dimensions specified in dim.

Author(s)

J. Durnez, B. Moerkerke, M. Welvaert

See Also

systemnoise, lowfreqdrift, physnoise, tasknoise, spatialnoise

Examples

d <- c(10,10,10)
sigma <- 5
nscan <- 100
rho <- c(0.3,-0.7)
out <- temporalnoise(d, nscan, sigma, rho, verbose=FALSE)

Results