Skip to contents

Engle-Granger two-step cointegration test

Usage

morie_eg_coint(y1, y2, max_lag = NULL)

Arguments

y1

Numeric, first series.

y2

Numeric, second series.

max_lag

Max ADF augmentation lags. Default floor(12*(n/100)^0.25).

Value

Named list with adf_statistic, p_value, beta, n, method.

Examples

morie_eg_coint(y1 = rnorm(100), y2 = rnorm(100))
#> $adf_statistic
#> [1] -5.554371
#> 
#> $p_value
#> [1] 0.005
#> 
#> $beta
#> [1] -0.03632531  0.05889223
#> 
#> $critical_values
#>    1%    5%   10% 
#> -3.90 -3.34 -3.04 
#> 
#> $n
#> [1] 100
#> 
#> $method
#> [1] "Engle-Granger 2-step cointegration (Engle & Granger 1987)"
#>