FCVARestn: Estimate FCVAR model

View source: R/FCVAR_estn.R

FCVARestnR Documentation

Estimate FCVAR model

Description

FCVARestn estimates the Fractionally Cointegrated VAR model. It is the central function in the FCVAR package with several nested functions, each described below. It estimates the model parameters, calculates the standard errors and the number of free parameters, obtains the residuals and the roots of the characteristic polynomial. print.FCVARestn prints the estimation results from the output of FCVARestn.

Usage

FCVARestn(x, k, r, opt)

Arguments

x

A matrix of variables to be included in the system.

k

The number of lags in the system.

r

The cointegrating rank.

opt

An S3 object of class FCVAR_opt that stores the chosen estimation options, generated from FCVARoptions().

Value

An S3 object of class FCVAR_model containing the estimation results, including the following parameters:

startVals

Starting values used for optimization.

options

Estimation options.

like

Model log-likelihood.

coeffs

Parameter estimates.

rankJ

Rank of Jacobian for the identification condition.

fp

Number of free parameters.

SE

Standard errors.

NegInvHessian

Negative of inverse Hessian matrix.

Residuals

Model residuals.

cPolyRoots

Roots of characteristic polynomial.

printVars

Additional variables required only for printing the output of FCVARestn to screen.

k

The number of lags in the system.

r

The cointegrating rank.

p

The number of variables in the system.

cap_T

The sample size.

opt

An S3 object of class FCVAR_opt that stores the chosen estimation options, generated from FCVARoptions().

See Also

FCVARoptions to set default estimation options. FCVARestn calls this function at the start of each estimation to verify validity of options. summary.FCVAR_model prints the output of FCVARestn to screen.

Other FCVAR estimation functions: FCVARoptions(), summary.FCVAR_model()

Examples


opt <- FCVARoptions()
opt$gridSearch   <- 0 # Disable grid search in optimization.
opt$dbMin        <- c(0.01, 0.01) # Set lower bound for d,b.
opt$dbMax        <- c(2.00, 2.00) # Set upper bound for d,b.
opt$constrained  <- 0 # Impose restriction dbMax >= d >= b >= dbMin ? 1 <- yes, 0 <- no.
x <- votingJNP2014[, c("lib", "ir_can", "un_can")]
m1 <- FCVARestn(x, k = 2, r = 1, opt)



opt1 <- opt
opt1$R_psi <- matrix(c(1, 0), nrow = 1, ncol = 2)
opt1$r_psi <- 1
m1r1 <- FCVARestn(x, k = 2, r = 1, opt1)



opt1 <- opt
opt1$R_Beta <- matrix(c(1, 0, 0), nrow = 1, ncol = 3)
m1r2 <- FCVARestn(x, k = 2, r = 1, opt1)



opt1 <- opt
opt1$R_Alpha <- matrix(c(0, 1, 0), nrow = 1, ncol = 3)
m1r4 <- FCVARestn(x, k = 2, r = 1, opt1)


FCVAR documentation built on May 5, 2022, 9:06 a.m.