predict {ARCensReg}R Documentation

Forecast for Autoregressive censored models with Normal and Student-t innovations

Description

Forecast from models fitted by ARCensReg and ARtCensReg.

Usage

  ## S3 method for class 'ARpCRM'
predict(object, x_pred, ...)
  
  ## S3 method for class 'ARtpCRM'
predict(object, x_pred, ...)

Arguments

object

An object inheriting from class ARpCRM or ARtpCRM, representing a fitted AR(p) censored linear model.

x_pred

Matrix of covariates for responses to be predicted.

...

Further arguments passed to or from other methods.

Value

A time series of predictions.

Author(s)

Fernanda L. Schumacher, Katherine L. Valeriano, Victor H. Lachos, Christian E. Galarza, and Larissa A. Matos

References

Schumacher FL, Lachos VH, Dey DK (2017). “Censored regression models with autoregressive errors: A likelihood-based perspective.” Canadian Journal of Statistics, 45(4), 375–392.

Valeriano KL, Schumacher FL, Galarza CE, Matos LA (2021). “Censored autoregressive regression models with Student- t innovations.” arXiv preprint arXiv:2110.00224.

See Also

ARCensReg, ARtCensReg

Examples


# Generating a sample
set.seed(2839)
n = 210
x = cbind(1, rnorm(n))
dat = rARCens(n=n, beta=c(-1,2), phi=.5, sig2=.3, x=x, cens='left', pcens=.1)

# Fitting the model
data1 = dat$data[1:205,]
fit = ARCensReg(data1$cc, data1$lcl, data1$ucl, data1$y, x[1:205,],
                 M=5, pc=.12, tol=0.001)

# Forecast
y_pred = predict(fit, x[206:n,])
mean((dat$data$y[206:n] - y_pred)^2) # MSPE

[Package ARCensReg version 3.0.1 Index]