arma_s_resid: arma_s_resid

View source: R/dependentData_Auxilliary_armaResid.R

arma_s_residR Documentation

arma_s_resid

Description

Computes the residuals of S-estimates for an ARMA process

Usage

arma_s_resid(x, beta_hat, p, q)

Arguments

x:

numeric vector. The signal

beta_hat:

numeric vector, the AR and MA coefficients

p:

AR order

q:

MA order

Value

a_sc: m-scale based on residuals.

Note

File is in dependentData_Auxiliary_armaResid.R

Examples


library(signal)
library(zeallot)
library(pracma)

N <- 500
a <- rnorm(N)
p <- 1
q <- 0
x <- signal::filter(1, c(1, -0.8), a)

beta_s <- arma_est_bip_s(x, p, q, tolX = 1e-8)
beta <- c(beta_s$ar_coeffs, beta_s$ma_coeffs)

arma_s_resid(x, beta, p, q)


Mufabo/Rrobustsp documentation built on June 11, 2022, 10:41 p.m.