Sug_dm {ADTSA}R Documentation

The Alternative Data Method

Description

This function performs the surrogate data method for testing auto (partial) correlations.

Usage

Sug_dm(ahat, ts, a1, a2, boot, lgmx)

Arguments

ahat

a vector of estimated acceleration constants for autocorrelations up to lagmax.

ts

a vector of time series data.

a1

the percentages for the lower limits of confidence intervals.

a2

the percentages for the upper limits of confidence intervals.

boot

number of bootstrap replications.

lgmx

maximum lag at which to calculate autocorrelations.

Value

A list with two components: acf and pacf.

For acf:

se: standard error estimates for autocorrelations.

CI: a list of estimated confidence intervals for autocorrelations. Contain two elements: per and BCa

For pacf:

se: standard error estimates for partial autocorrelations.

CI: a list of estimated confidence intervals for partial autocorrelations. Contain two elements: per and BCa

Author(s)

Hossein hassani, Masoud yarmohammadi, Mohammad reza yeganegi and Leila Marvian Mashhad.

Examples

set.seed(123)
ts <- rnorm(100)

ahat <- list(acf=c() ,pacf=c())
ahat$acf <- acf(ts, lag.max = 19, plot = FALSE)$acf[,,1]
ahat$pacf <- pacf(ts, lag.max = 19, plot = FALSE)$acf[,,1]

a1 <- 0.025
a2 <- 0.975
boot <- 100
lgmx <- 20

Sug_dm(ahat, ts, a1, a2, boot, lgmx)
   

[Package ADTSA version 1.0.1 Index]