RATS 10.1
RATS 10.1

Instructions /

SYSTEM etc Instructions

Home Page

← Previous Next →

SYSTEM(options)   list of equations(omit list if using MODEL option)

VARIABLES list of endogenous variables

LAGS      list of lags

DETERMINISTIC deterministic/additional variables(in Regression Format)

ECT       list of equations

END(SYSTEM)
 

This collection of instructions sets up a standard vector autoregression. This is the recommended order, although all that is required is that SYSTEM come first and END(SYSTEM) last. VAR systems are normally estimated with the ESTIMATE instruction.

 

You can also use SYSTEM (without VARIABLES, LAGS, DETERMINISTIC, or ECT, but with END(SYSTEM)) to group a set of previously defined equations into a system for estimation or for Kalman filter work.

 

SPECIFY, KFSET and TVARYING are also subcommands of SYSTEM. SPECIFY is used to specify a Bayesian prior for a vector autoregression, KFSET and TVARYING set up information for Kalman filtering.

Wizard

You can use the Time Series—VAR (Setup/Estimate) Wizard to define and estimate VAR models.

Options for SYSTEM

MODEL=model name [unused]

The MODEL option defines the equations in the system as a MODEL variable. If you use MODEL, omit the list of equations.

The MODEL option makes using instructions such as FORECAST, IMPULSE, and HISTORY easier—rather than having to list each equation on a supplementary card, you just use the MODEL option on those instructions to reference the system. If you are going to use the ECT instruction to add error-correction terms to your model, you must use MODEL.

 

CMOMENT/[NOCMOMENT]

Use the CMOMENT option when you are putting together a system of very similar but not identical equations. It will reduce the computation time in estimating the systems, though that is no longer an issue in practice.

Examples

compute lags=4                                ;*Number of lags

*

system(model=varmodel)

variables gdph fm1

lags 1 to lags

det constant

end(system)

 

This sets up a simple two variable VAR with four lags. The number of lags can be altered by changing the value on the COMPUTE LAGS instruction.


 

system(model=nominal)

variables logp logm2

lags 1 to 4

det constant

end(system)

*

system(model=real)

variables loggdp unemp logi

lags 1 to 4

det constant logp{1 to 4} logm2{1 to 4}

end(system)

 

This sets up a five variable "near-VAR" with LOGP and LOGM2 set up as an "exogenous block". The lags of all five variables enter into the LOGGDP, UNEMP and LOGI equations, but only LOGP and LOGM2 are in the equations for those two variables. The full five variable MODEL can be written NOMINAL+REAL.


 

equation(coeffs=||1.0,1.0||) pppeq logpx

# logpy logexr

system(model=cointmodel)

variables logpx logpy logexr

lags 1 to 6

det constant

ect pppeq

end(system)

 

creates a cointegrated system of three variables with the cointegrating relationship

 

\(\log \,{P_x} = \log \,{P_y} + \log \,X\)

 

where \({P_x}\) and \({P_y}\) are price indices and \(X\) is the exchange rate linking the countries’ currencies.


 

system(model=ratemod)

variables  shortrat  longrate  m1  twdollar

lags 1 2 3 4 6 9 12

det constant

end(system)

 

creates a four variable VAR. Using the older “numbered equations” method, this would be:

 

system 1 to 4

variables  shortrat  longrate  m1  twdollar

lags 1 2 3 4 6 9 12

det constant

end(system)


Copyright © 2025 Thomas A. Doan