/* ** Lesson 14.3: Cointegration Test ** Johansen Approach */ use gpe2; output file = gpe\output14.3 reset; load z[67,3] = gpe\usyc87.txt; y = z[2:67,2]; c = z[2:67,3]; ns = {"c","y"}; data = y~c; @ data matrix for cointegration test @ call reset; _rstat=1; _method=3; _dlags=3; @ find the proper order p @ call estimate(data,0); @ for VAR(p) model estimation @ @ Johansen cointegration test based on VAR(3) model @ call johansen(data,3,2); @ model with trend drift @ call johansen(data,3,1); @ model with drift only @ call johansen(data,3,0); @ model with no drift @ end; #include gpe\johansen.gpe;