Learn R Programming

garchx (version 1.6)

coef.garchx: Extraction functions for 'garchx' objects

Description

Extraction functions for objects of class 'garchx'

Usage

# S3 method for garchx
coef(object, ...)
  # S3 method for garchx
confint(object, parm, level = 0.95, ...)
  # S3 method for garchx
fitted(object, as.zoo = TRUE, ...)
  # S3 method for garchx
logLik(object, ...)
  # S3 method for garchx
nobs(object, ...)
  # S3 method for garchx
predict(object, n.ahead = 10, newxreg = NULL,
    newindex = NULL, n.sim = NULL, verbose = FALSE, ...)
  # S3 method for garchx
print(x, ...)
  # S3 method for garchx
quantile(x, probs=0.025, names = TRUE, type = 7, as.zoo = TRUE, ...)
  # S3 method for garchx
residuals(object, as.zoo = TRUE, ...)
  # S3 method for garchx
toLatex(object, digits = 4, ...)
  # S3 method for garchx
vcov(object, vcov.type = NULL, ...)

Value

coef:

numeric vector containing parameter estimates

confint:

A matrix lower and upper confidence limits for each parameter

fitted:

fitted conditional variance

logLik:

log-likelihood (normal density)

nobs:

the number of observations used in the estimation

predict:

a vector with the predictions (verbose=FALSE), or a matrix with both the predictions and the simulations (verbose=TRUE)

print:

print of the estimation results

quantile:

the fitted quantiles, i.e. the conditional standard deviation times the empirical quantile of the standardised innovations

residuals:

standardised residuals

vcov:

coefficient variance-covariance matrix

Arguments

object

an object of class 'garchx'

x

an object of class 'garchx'

parm

a specification of which parameters are to be given confidence intervals, either a vector of numbers or a vector of names. If missing, all parameters are considered

level

numeric value between 0 and 1 (the confidence level required)

as.zoo

logical. If TRUE, then the returned result is of class zoo

n.ahead

integer that determines how many steps ahead predictions should be generated

newxreg

vector or matrix with the out-of-sample regressor values

newindex

zoo-index for the out-of-sample predictions. If NULL (default), then 1:n.ahead is used

n.sim

NULL or an integer, the number of simulations

verbose

logical. If TRUE, then the simulations - in addition to the predictions - are returned

probs

vector of probabilities

names

logical, whether to return names or not

type

integer that determines the algorithm used to compute the quantile, see quantile

digits

integer, the number of digits in the printed LaTeX code

vcov.type

NULL or character that is (partially) matched to "ordinary", "robust" or "hac". The robust coefficient-covariance ("robust") is that of Francq and Thieu (2019). The Heteroscedasticity and Autocorrelation Consistent ("hac") variance-covariance estimates the variance of the score (the 'meat') based on Theorem 2.2 in De Jong and Davidson (2000). For the details of the kernel weights (Bartlett) and bandwidth, see the code in the vcov.garchx function

...

additional arguments

Author

Genaro Sucarrat, https://www.sucarrat.net/

References

Christian Francq and Le Quien Thieu (2019): 'QML inference for volatility models with covariates', Econometric Theory 35, pp. 37-72, tools:::Rd_expr_doi("10.1017/S0266466617000512") Robert M. de Jong and James Davidson (2000): 'Consistency of Kernel Estimators of Heteroscedastic and Autocorrelated Covariance Matrices', Econometrica 68, pp. 407-423

See Also

garchx, garchxSim, zoo

Examples

Run this code
##simulate from a garch(1,1):
set.seed(123)
y <- garchxSim(1000)

##estimate garch(1,1) model:
mymod <- garchx(y)

##print estimation results:
print(mymod)

##extract coefficients:
coef(mymod)

##extract and store conditional variances:
sigma2hat <- fitted(mymod)

##extract log-likelihood:
logLik(mymod)

##extract and store standardised residuals:
etahat <- residuals(mymod)

##extract coefficient variance-covariance matrix:
vcov(mymod)

##generate predictions:
predict(mymod)

Run the code above in your browser using DataLab