Learn R Programming

tsapp (version 1.0.4)

Grangercaus: Grangercaus determines three values of BIC from a twodimensional VAR process

Description

Grangercaus determines three values of BIC from a twodimensional VAR process

Usage

Grangercaus(x, y, p)

Arguments

x

first time series

y

second time series

p

maximal order of VAR process

Value

out list with components

BIC

vector of length 3:

ll BIC1 minimum aic value for all possible lag structures BIC2 minimum aic value when Y is not included as regressor in the equation for X BIC3 minimum aic value when X is not included as regressor in the equation for Y
out1

output of function lm for regression equation for x-series

out2

output of function lm for regression equation for y-series

Examples

Run this code
# NOT RUN {
data(ICECREAM)
out <- Grangercaus(ICECREAM[,1],ICECREAM[,2],3) 
# }

Run the code above in your browser using DataLab