qser2ar: Autoregression (AR) Model of Quantile Series

View source: R/qfa5.0.R

qser2arR Documentation

Autoregression (AR) Model of Quantile Series

Description

This function fits an autoregression (AR) model to quantile series (QSER) separately for each quantile level using stats::ar().

Usage

qser2ar(
  y.qser,
  p = NULL,
  order.max = NULL,
  method = c("none", "gamm", "sp"),
  spar = NULL,
  type = c(1, 2)
)

Arguments

y.qser

matrix or array of pre-calculated QSER, e.g., using qser()

p

order of AR model (default = NULL: selected by AIC)

order.max

maximum order for AIC if p = NULL (default = NULL: determined by stats::ar())

method

quantile smoothing method: "gamm" for mgcv::gamm(), "sp" for stats::smooth.spline(), or "none" (default)

spar

smoothing parameter for stats::smooth.spline() (default = NULL for GCV)

type

type of smoothing for covariance matrix: 1 (direct, default) or 2 (square root)

Value

a list with the following elements:

A

matrix or array of AR coefficients

V

vector or matrix of residual covariance

p

order of AR model

n

length of time series

residuals

matrix or array of residuals


qfa documentation built on March 30, 2026, 5:07 p.m.

Related to qser2ar in qfa...