dS_lin2_loop: Straightforward calculation of simplicial depth for AR(1)...

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

View source: R/dS_lin2_loop.R

Description

The function calculates simplicial depth for AR(1) processes with intercept as discussed in Leucht, Mueller and Kustosz (2014) by nested loops. The default model thereby is defined by

Y_n= θ_0+θ_1 Y_{n-1} + E_n

and med(E_n)=0. However, other models are selectable.

Usage

1
dS_lin2_loop(theta, y)

Arguments

theta

Parameter θ in which dS is evaluated.

y

Observed data y = (y_0,...,y_N) for which dS is evaluated.

Details

The theoretical details can be found in Kustosz, Leucht and Mueller (2016). The computational details are in Kustosz (2016).

Value

The function returns dS for given theta and y.

Note

The function is not really efficient for large samples. Use dS_lin2 instead.

Author(s)

Kustosz, Christoph

References

Kustosz, C. (2016). Depth based estimators and tests for autoregressive processes with application. Ph. D. thesis. TU Dortmund.

Kustosz C., Leucht A. and Mueller Ch. H. (2016). Tests based on simplicial depth for AR(1) models with explosion. Journal of Time Series Analysis. In press.

See Also

dS_lin2

Examples

1
2
3
4
y <- RandomARMod_lin2(15, 0.2, 1.01, 15, "0")
theta <- c(0.2, 1.01)
dS_lin2_loop(theta = theta, y = y)
dS_lin2_loop(theta = theta + 0.1, y = y)

ChrisKust/rexpar documentation built on May 6, 2019, 11:48 a.m.