Learn R Programming

FluxPoint (version 0.1.2)

estimate_RWVAR_cp: Robust parameter estimation (RPE) for univariate time series

Description

Implements the robust parameter estimation (RPE) procedure to estimate the parameters \(\sigma_{\eta}^2\), \(\sigma_{\nu}^2\), and \(\phi\) in the univariate version of the proposed model. The method is based on minimizing the objective function defined in objective_func, using variance estimates computed from lagged differences of the data.

Usage

estimate_RWVAR_cp(
  data,
  L = 15,
  phiLower = -0.8,
  phiUpper = 0.8,
  sigetaLower = 0,
  sigetaUpper = Inf,
  signuLower = 1e-06,
  signuUpper = Inf,
  num_inis = 20,
  CPs = NULL
)

Value

A list with elements:

  • `sigeta_est` — Estimated \(\sigma_{\eta}^2\).

  • `signu_est` — Estimated \(\sigma_{\nu}^2\).

  • `phi_est` — Estimated autoregressive coefficient \(\phi\).

  • `inis` — Initial parameter values used in optimization.

Arguments

data

Numeric vector containing the univariate time series observations \(y_{1:n}\).

L

Integer; number of lag differences used in the estimation (default = 15).

phiLower, phiUpper

Numeric; lower and upper bounds for the autoregressive coefficient \(\phi\).

sigetaLower, sigetaUpper

Numeric; lower and upper bounds for \(\sigma_{\eta}^2\), the random walk innovation variance.

signuLower, signuUpper

Numeric; lower and upper bounds for \(\sigma_{\nu}^2\), the VAR(1) innovation variance.

num_inis

Integer; number of initial values of \(\phi\) used for grid search initialization (default = 20).

CPs

Optional numeric vector of change point locations (indices). If provided, differenced data crossing these points are removed to improve the robustness of the variance estimation in the presence of structural breaks.

Details

For each lag \(l = 1, \ldots, L\), the function computes the variance of the \(l\)-lagged differences \(z^{(l)}_t = y_{t+l} - y_t\) using the median absolute deviation (MAD). If change points (CPs) are specified, all differences that overlap a change point are excluded from the computation. The resulting empirical variances \(\{v^{(l)}\}_{l=1}^L\) are then used to construct the following optimization problem: $$\sum_{l=1}^L \left(l\sigma^2_{\eta} + 2\frac{1-\phi^l}{1-\phi^2}\sigma^2_{\nu} - v^{(l)}\right)^2,$$ which is solved via bounded optimization using optim() with the L-BFGS-B algorithm. Initial parameter values are obtained using non-negative least squares (NNLS) regression over a grid of \(\phi\) values.