preaverage {ccid}R Documentation

Preaveraging the multivariate time series

Description

This function pre-processes the given data in order to remove serial correlation that might exist in the given data.

Usage

preaverage(X, scal = 3)

Arguments

X

A numerical matrix representing the multivariate time series, with the columns representing its components.

scal

A positive integer number with default value equal to 3. It is used to define the way we pre-average the data sequences.

Details

For a given natural number scal and data matrix X of dimensionality T×dT \times d, let us denote by Q=T/scalQ = \lceil T/scal \rceil. Then, preaverage calculates, for all j=1,2,...,dj = 1,2, ..., d,

X~q,j=1/scalt=(q1)sc+1qscXt,j,\tilde{X}_{q, j} = 1/scal\sum_{t=(q-1) * sc + 1}^{q * sc}X_{t, j},

for q=1,2,...,Q1q=1, 2, ..., Q-1, while

x~Q,j=(T(Q1)sc)1t=(Q1)sc+1TXt,j.\tilde{x}_{Q, j} = (T - (Q-1) * sc)^{-1}\sum_{t = (Q-1) * sc + 1}^{T}X_{t, j}.

Value

The “preaveraged” matrix X~\tilde{X} of dimensionality Q×dQ \times d, as explained in Details.

Author(s)

Andreas Anastasiou, anastasiou.andreas@ucy.ac.cy

References

“Cross-covariance isolate detect: a new change-point method for estimating dynamic functional connectivity”, Anastasiou et al (2020), preprint <doi:10.1101/2020.12.20.423696>.

Examples

A <- matrix(1:32, 8, 4)
A
A1 <- preaverage(A, scal = 3)
A1

[Package ccid version 1.2.0 Index]