dbacf_AR1 {dbacf} | R Documentation |
Robust dbacf in change point regression with AR(1) errors
Description
In the context of change point regression with a stationary AR(1) error process, this function estimates the autoregressive coefficient along with the autocovariance/correlation function as a function of given lags.
Usage
dbacf_AR1(data, type = c("covariance", "correlation"), lags)
Arguments
data |
numeric vector or a univariate object of class |
type |
character string specifying whether covariance (default) or correlation must be computed. |
lags |
numeric giving the number of lags to compute. |
Value
An object of class "dbacf" containing:
-
acf
numeric vector of lengthlags + 1
giving estimated (auto)covariance/correlation function -
rho
numeric, estimate of autoregressive coefficient -
acfType
string indicating whethercovariance
orcorrelation
has been computed -
n
integer givinglength(data)
References
Chakar, S. and Lebarbier, E. and Lévy-Leduc, C. and Robin, S. (2017). A robust approach for estimating change-points in the mean of an AR(1) process, Bernoulli, 23(2), 1408-1447
Examples
ar1 <- arima.sim(n = 50, model = list(ar = c(0.5), order = c(1, 0, 0)),
sd = 0.25)
dbacf_AR1(ar1, type="correlation", lags=10)