getSSAsignal: Parametric method for identifying trends and periodic...

Description Usage Arguments Details Value Author(s) References See Also Examples

Description

Signal detection algorithm based on ideas of Vautard et.al. (1992) and Alexandrov (2008a,b)

Usage

1
2
3
4
5
getSignal(dSSA, ...)
## S3 method for class 'decompSSA'
getSignal(dSSA, omega0=1/dSSA$L,C0,r0,...)
getTrend(U,omega0=1/nrow(U),C0)
getPeriod(U,r0)

Arguments

dSSA

An object of class decompSSA.

omega0

Low frequency boundary.

C0

Low frequency contribution.

r0

Dominant frequency contribution.

U

Matrix of SSA - Eigenvectors.

...

Further arguments to be passed to different methods.

Details

This signal selection algorithm is based on the fact that the SSA - Eigenvectors U^i for trends and periodic components have a simple shape and their periodogram

Pi^i(omega) = 1/L |sum_n{exp(-i 2 pi omega n)}

is governed by a dominant frequency. (The periodogram is determined by means of fft and therefore the spacing of omega is the Nyquist frequency 1/L.)

The trend extraction is based on the idea that the $U^(i)$ contributing to a trend have large periodogram values only for low frequencies <= omega_0. The contribution of low frequencies is determined by

C(U^i,omega) = sum_{omega <= omega_0}{Pi(omega)} / sum_{omega <= 0.5}{Pi(omega)}

U^i are considered to represent a trend component if C(U^i,omega_0) <= C0 (see argument C0).

The selection of periodic components is based on the fact that such components produce pairs of Eigenvalues and Eigenvectors (U^i, U^i+1). Such pairs have almost equal eigenvectors and the dominant frequency

omega*^i = argmax {Pi(omega)}

of the Eigenvectors is similar. This is the case if the following condition is met:

delta^i = | omega*^i - omega*^(i+1) |

(As the Pi(omega) is estimated via fft, delta^i has to be 0 to fulfill that criterion, meaning that omega*^i and omega*^(i+1) are equal.)

The above criterion may produce so called "false alarms". Therefore it is in addition necessary to check whether the Eigenvectors U^i are really governed by one single frequency. This is done by checking whether the dominant frequency explains enough of the variance of Pi(omega). This is checked by the criterion

R^i = max{0.5( gamma^i(omega) + gamma^i(omega + 1/L))}

where

gamma^i(omega_k) = Pi^i(omega_k)/sum{Pi^i(omega)} + Pi^(i+1)(omega_k)/sum{Pi^(i+1)(omega)}

The term gamma^i(omega + 1/L) is to account for smearing of the periodogram in the case of signals with frequencies that are not multiples of 1/L. U^i and U^(i+1) are considered to represent a quasi periodic component if R^i <= r_0 (see argument r0).

If SSA Eigenelements are detected as contributing to the trend and the (quasi) periodic components they are only assigned to the periodicities.

Value

An object of class SSAsignal

periodic

A (possibly empty) data.frame. Each row is associated with a quasi periodic component, containing the following informations in its columns: \beginitemize \itemk1,k2The rank of the Eigenelements contributing to the quasi periodic component \itemfreqThe frequency of the maximal value of the power spectrum of the corresponding Eigenvectors (dominant frequency). \itemsmoothnessApproximately the proportion of variance explained by the dominant frequency. \itemexplainedVariancePercentage of the variance explained by the Eigenvalues with the rank k1,k2 \enditemize

trend

A (possibly empty) data.frame. Each row is associated with a trend component, containing the following informations in its columns: \beginitemize \itemkThe rank of the Eigenelements contributing to the trend component \itemsmoothnessThe proportion of variance explained by the frequencies ≤q omega0. \itemexplainedVariancePercentage of the variance explained by the Eigenvalues with the rank k \enditemize

trendAndPeriod

A (possibly empty) vector kontaining the rank numbers of the Eigenelements that have been identified as contributing to trends and quasi periodic components. These elements are all considered to correspond to periodicities and are therefore not listed in trend.

call

Call of the generating function

Author(s)

Lukas Gudmundsson

References

Alexandrov, T. A Method of Trend Extraction Using Singular Spectrum Analysis ArXiv e-prints, 2008, 804.

Alexandrov, T. A method of extraction of quasi-periodic time series components using Singular Spectrum Analysis 2008.

Vautard, R.; Yiou, P. & Ghil, M. Singular-spectrum analysis: a toolkit for short, noisy chaotic signals Physica D-Nonlinear Phenomena, Elsevier North-Holland, Inc. New York, NY, USA, 1992, 58, 95-126.

See Also

decompSSA, decompSSAM, plot.sdTest,MCSSA

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
## Artifitial Time series
set.seed(120)
n <- arima.sim(n=200,alist(ar=0.4))
n <- as.vector(scale(n))
x <- sin(seq(0,20*pi,len=200)) + 0.01*(1:200)
## To enable the interpretation of the eigenvectors
## as a representation of explained variance: remove the mean
xn <- scale(x+n/2,center=TRUE,scale=FALSE)
xn.dc <- decompSSA(xn,L=40)

## Identify signal
## It may happen that no or spurious signals are detected due to noise
(xn.signal <- getSignal(xn.dc,C0=0.85,r0=0.85))

## reconstruct signal (trend and period)
trendInd <- as.numeric(xn.signal$trend[,1])
perInd <- as.numeric(as.matrix(xn.signal$period[,1:2]))
xn.trend <- reconSSA(xn.dc,xn,list(trendInd))
xn.period <- reconSSA(xn.dc,xn,list(perInd))

plot(xn,t="l")
lines(xn.trend,lwd=2,col="red")
lines(xn.period,lwd=2,col="blue")
legend("bottomright",legend=c("Trend","Period","xn"),
lwd=c(2,2,1),col=c("red","blue","black")) 

simsalabim documentation built on May 2, 2019, 5:56 p.m.