Hello everyone -
I am trying to reconcile the methodology used by Enders to estimate a VAR and determine the cointegration vector using the Johansen framework (Enders pages 397-to-401) with the same as highlighted by Dr. Bernhard Pfaff in his book. My intent for the moment is to determine whether a cointegration vector exists among X variables and if so the value of the estimates in the cointegration vector. According to Enders - the methodology is as follows: 1) Determine order of integration of each variable. I have 4 variables that are I(1) - all are stock prices. 2) Determine optimal number of lag length to be included in the VAR. I do this via the VARselect function in the 'vars' package in R as highlighted in Dr. Pfaff's book. > infocrit <- VARselect(vardat, lag.max=20, type="const") > infocrit $selection AIC(n) HQ(n) SC(n) FPE(n) 17 3 2 17 FIRST QUESTION: As you can see I have a conflict with the information criteria. How does one reconcile the conflict in terms of the number of lags to include in the VAR? Enders uses another method that estimates VARs with different lag lengths and then uses the likelihood ratio test (page 397 Enders). 3) Estimate the model and determine the rank of ∏. > H1 <- ca.jo(vardat, type='trace', ecdet='const', K=17) On a side note I also estimated the VAR by using "varestimate <- VAR(vardat, p=17, type="const")". I checked the residuals of each equation in the VAR for serial correlation and normality (the residuals were white noise). ---------- snippet of output of ca.jo()------------- test 10pct 5pct 1pct r <= 3 | 2.20 7.52 9.24 12.97 r <= 2 | 6.63 17.85 19.96 24.60 r <= 1 | 15.47 32.00 34.91 41.07 r = 0 | 50.11 49.65 53.12 60.16 Eigenvectors, normalised to first column: (These are the cointegration relations) V1.l17 V2.l17 V3.l17 V4.l17 constant V1.l17 1.0000000 1.0000000 1.0000000 1.0000000 1.00000000 V2.l17 -0.2041193 -1.1345264 -0.3982231 -0.4862289 -0.21197975 V3.l17 -0.2584363 2.6858123 -0.8965070 -0.7727329 -0.43277884 V4.l17 -0.5167626 -0.8169243 -0.4955091 0.5102647 0.06214863 constant 5.2281138 -65.4213338 84.4998981 28.3856062 0.05660371 SECOND QUESTION: Since I supplied K=17 lags (as per the AIC and FPE criterion) I'm not quite sure how to interpret the output of ca.jo(). Here is my understanding. Based on the trace test, I can reject the null: r=0 at the 90% critical value and accept r > 0. However, I must accept the null: r<= 1 given 15.47 is less than the critical values at all significance levels. So this means I have 1 cointegration vector and from documentation for ca.jo() I believe it is that depicted in the first column under the "These are the cointegration relations" heading. However, I am confused by the 'l17' suffix in each of the variables in the output. I know I have up to 17 lags in my VAR as per the AIC and FPE criterion but what does this actually say about the equilibrium relationship? Would I be incorrect to say that the equilibrium (cointegration equation) is the following: V1 - 0.2041193*V2 - 0.2584363*V3 - 0.5167626*V4 + 5.2281138 = residuals I would greatly appreciate it if someone could help steer me in the right direction. Thank you. |
Dear Algotrader,
it is encountered quite often that IC will lead to different lag-specifications. In your case, I would opt for the SC or the HQ, i.e. a more parsimonuous specification and the values reported for the AIC and FPE look suspiciously high. Next, a VECM can be specified in different flavors and here you have used its long-run form. See ?ca.jo for a description and the arguments. Best, Bernhard > -----Ursprüngliche Nachricht----- > Von: [hidden email] > [mailto:[hidden email]] Im Auftrag von algotr8der > Gesendet: Dienstag, 26. April 2011 04:30 > An: [hidden email] > Betreff: [R-SIG-Finance] cointegration using Johansen for VAR > > Hello everyone - > > I am trying to reconcile the methodology used by Enders to > estimate a VAR and determine the cointegration vector using > the Johansen framework (Enders pages 397-to-401) with the > same as highlighted by Dr. Bernhard Pfaff in his book. > > My intent for the moment is to determine whether a > cointegration vector exists among X variables and if so the > value of the estimates in the cointegration vector. > > According to Enders - the methodology is as follows: > > 1) Determine order of integration of each variable. > > I have 4 variables that are I(1) - all are stock prices. > > 2) Determine optimal number of lag length to be included in the VAR. > > I do this via the VARselect function in the 'vars' package in > R as highlighted in Dr. Pfaff's book. > > > infocrit <- VARselect(vardat, lag.max=20, type="const") > > > infocrit > $selection > AIC(n) HQ(n) SC(n) FPE(n) > 17 3 2 17 > > FIRST QUESTION: As you can see I have a conflict with the > information criteria. How does one reconcile the conflict in > terms of the number of lags to include in the VAR? Enders > uses another method that estimates VARs with different lag > lengths and then uses the likelihood ratio test (page 397 Enders). > > 3) Estimate the model and determine the rank of ∏. > > > H1 <- ca.jo(vardat, type='trace', ecdet='const', K=17) > > On a side note I also estimated the VAR by using "varestimate > <- VAR(vardat, p=17, type="const")". > I checked the residuals of each equation in the VAR for > serial correlation and normality (the residuals were white noise). > > ---------- snippet of output of ca.jo()------------- > > test 10pct 5pct 1pct > r <= 3 | 2.20 7.52 9.24 12.97 > r <= 2 | 6.63 17.85 19.96 24.60 > r <= 1 | 15.47 32.00 34.91 41.07 > r = 0 | 50.11 49.65 53.12 60.16 > > Eigenvectors, normalised to first column: > (These are the cointegration relations) > > V1.l17 V2.l17 V3.l17 > V4.l17 > constant > V1.l17 1.0000000 1.0000000 1.0000000 > 1.0000000 1.00000000 > V2.l17 -0.2041193 -1.1345264 -0.3982231 > -0.4862289 -0.21197975 > V3.l17 -0.2584363 2.6858123 -0.8965070 > -0.7727329 -0.43277884 > V4.l17 -0.5167626 -0.8169243 -0.4955091 > 0.5102647 0.06214863 > constant 5.2281138 -65.4213338 84.4998981 28.3856062 > 0.05660371 > > > SECOND QUESTION: Since I supplied K=17 lags (as per the AIC and FPE > criterion) I'm not quite sure how to interpret the output of ca.jo(). > > Here is my understanding. Based on the trace test, I can > reject the null: > r=0 at the 90% critical value and accept r > 0. However, I > must accept the > null: r<= 1 given 15.47 is less than the critical values at > all significance levels. So this means I have 1 cointegration > vector and from documentation for ca.jo() I believe it is > that depicted in the first column under the "These are the > cointegration relations" heading. > > However, I am confused by the 'l17' suffix in each of the > variables in the output. I know I have up to 17 lags in my > VAR as per the AIC and FPE criterion but what does this > actually say about the equilibrium relationship? > > Would I be incorrect to say that the equilibrium > (cointegration equation) is the following: > > V1 - 0.2041193*V2 - 0.2584363*V3 - 0.5167626*V4 + 5.2281138 = > residuals > > I would greatly appreciate it if someone could help steer me > in the right direction. Thank you. > > -- > View this message in context: > http://r.789695.n4.nabble.com/cointegration-using-Johansen-for > -VAR-tp3474574p3474574.html > Sent from the Rmetrics mailing list archive at Nabble.com. > > _______________________________________________ > [hidden email] mailing list > https://stat.ethz.ch/mailman/listinfo/r-sig-finance > -- Subscriber-posting only. If you want to post, subscribe first. > -- Also note that this is not the r-help list where general R > questions should go. > Confidentiality Note: The information contained in this message, and any attachments, may contain confidential and/or privileged material. It is intended solely for the person(s) or entity to which it is addressed. Any review, retransmission, dissemination, or taking of any action in reliance upon this information by persons or entities other than the intended recipient(s) is prohibited. If you received this in error, please contact the sender and delete the material from any computer. ***************************************************************** _______________________________________________ [hidden email] mailing list https://stat.ethz.ch/mailman/listinfo/r-sig-finance -- Subscriber-posting only. If you want to post, subscribe first. -- Also note that this is not the r-help list where general R questions should go. |
Hi Dr. Bernhard,
Thank you for the clarification on the lag terms. I will use your advice in building my model. That being said, the output of ca.jo still confuses me. THe cointegration vector should describe the long-run (in my case) equilibrium in the levels of the variables and I guess the 'l17' suffix attached to the variables in the output of ca.jo is confusing me. This is not explained in the documentation. Eigenvectors, normalised to first column: (These are the cointegration relations) V1.l17 V2.l17 V3.l17 V4.l17 constant V1.l17 1.0000000 1.0000000 1.0000000 1.0000000 1.00000000 V2.l17 -0.2041193 -1.1345264 -0.3982231 -0.4862289 -0.21197975 V3.l17 -0.2584363 2.6858123 -0.8965070 -0.7727329 -0.43277884 V4.l17 -0.5167626 -0.8169243 -0.4955091 0.5102647 0.06214863 constant 5.2281138 -65.4213338 84.4998981 28.3856062 0.05660371 My understanding is that the long-run equilibrium cointegration relationship is in the levels of the variables as follows: V1 - 0.2041193*V2 - 0.2584363*V3 - 0.5167626*V4 + 5.2281138 = residuals Would this be an accurate statement? Thank you kindly for your help. |
`l17` signify the seventeenth lag of a variable. Choose the other specification, and you will observe `l1`. You are confused by VECM and the Two-step Engle-Granger procedure. The available specifications of a VECM are given in ?ca.jo from the meaning of the `lfoo` could be interferred, too.
Best, Bernhard > -----Ursprüngliche Nachricht----- > Von: [hidden email] > [mailto:[hidden email]] Im Auftrag von algotr8der > Gesendet: Dienstag, 26. April 2011 20:12 > An: [hidden email] > Betreff: Re: [R-SIG-Finance] cointegration using Johansen for VAR > > Hi Dr. Bernhard, > > Thank you for the clarification on the lag terms. I will use > your advice in building my model. > > That being said, the output of ca.jo still confuses me. THe > cointegration vector should describe the long-run (in my > case) equilibrium in the levels of the variables and I guess > the 'l17' suffix attached to the variables in the output of > ca.jo is confusing me. This is not explained in the documentation. > > Eigenvectors, normalised to first column: > (These are the cointegration relations) > > V1.l17 V2.l17 V3.l17 > V4.l17 > constant > V1.l17 1.0000000 1.0000000 1.0000000 > 1.0000000 1.00000000 > V2.l17 -0.2041193 -1.1345264 -0.3982231 > -0.4862289 -0.21197975 > V3.l17 -0.2584363 2.6858123 -0.8965070 > -0.7727329 -0.43277884 > V4.l17 -0.5167626 -0.8169243 -0.4955091 > 0.5102647 0.06214863 > constant 5.2281138 -65.4213338 84.4998981 28.3856062 > 0.05660371 > > My understanding is that the long-run equilibrium > cointegration relationship is in the levels of the variables > as follows: > > V1 - 0.2041193*V2 - 0.2584363*V3 - 0.5167626*V4 + 5.2281138 = > residuals > > Would this be an accurate statement? Thank you kindly for your help. > > > > -- > View this message in context: > http://r.789695.n4.nabble.com/cointegration-using-Johansen-for > -VAR-tp3474574p3476132.html > Sent from the Rmetrics mailing list archive at Nabble.com. > > _______________________________________________ > [hidden email] mailing list > https://stat.ethz.ch/mailman/listinfo/r-sig-finance > -- Subscriber-posting only. If you want to post, subscribe first. > -- Also note that this is not the r-help list where general R > questions should go. > Confidentiality Note: The information contained in this ...{{dropped:10}} _______________________________________________ [hidden email] mailing list https://stat.ethz.ch/mailman/listinfo/r-sig-finance -- Subscriber-posting only. If you want to post, subscribe first. -- Also note that this is not the r-help list where general R questions should go. |
Free forum by Nabble | Edit this page |