Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • CS-ARDL Approach

    Hi All,
    I have tried to estimate the CS-ARDL model by applying balance panel of 141 countries for three lags order using Dr Kamiar Mohaddes's Stata command as a follow:

    xtpmg d.dlogREER d.dlogROILP d.dlogGDPPC d.dlogGE dlogREERbar dlogROILPbar dlogGDPPCbar dlogGEbar ldlogREERbar ldlogROILPbar ldlogGDPPCbar ldlogGEbar l2dlogREERbar l2dlogROILPbar l2dlogGDPPCbar l2dlogGEbar l3dlogREERbar l3dlogROILPbar l3dlogGDPPCbar l3dlogGEbar, lr ( l.dlogREER dlogROILP dlogGDPPC dlogGE) replace mg

    So, the Stata command did not work and I got conformability erro

    Anyone knows what does it mean or how can I solved.

    Thanks

  • #2
    Hi Marwan,
    can you provide a few more details of the error message and your data. Conformability error can mean a lot.

    Do other commands such as xtdcce2 work?
    Jan

    Comment


    • #3
      Hi Jan,

      Many thanks for your reply... This is the Stata command, which was taken from Mohtades. But, I wonder why did he use second differences for Y and X in the beginning of the command. Now, it gives me a different error, which is below... Does xtdcce2 for CS-ARDL approach ?


      . xtpmg d.dlogREER d.dlogOILR d.dlogGDPPC d.dlogGE dlogREERbar dlogOILRbar dlogGDPPCbar dlogGEbar ldlogREERbar ldlogOILRbar ldlogGDPPCbar ld
      > logGEbar l2dlogREERbar l2dlogOILRbar l2dlogGDPPCbar l2dlogGEbar l3dlogREERbar l3dlogOILRbar l3dlogGDPPCbar l3dlogGEbar, lr ( l.dlogREER dlo
      > gOILR dlogGDPPC dlogGE) replace mg

      expression (-_b[dlogOILR]/_b[L.dlogREER]) evaluates to missing
      r(498);

      Comment


      • #4
        In order to estimate an ARDL model with xtpmg, you need to rewrite your model such that only one coefficient represents the long run coefficient. xtpmg estimates ECMs, which need to be transformed into first differences.
        Your error looks like that one of the coefficients is missing.

        xtdcce2 can estimate CS-ARDL models and no transformations of your equation are necessary. xtdcce2 is available on SSC or can be directly installed using my webpage:
        Code:
         net install xtdcce2 , from(http://www.ditzen.net/Stata/)
        A set of slides from the User Group Meeting in Zurich describing the command and how to estimate the long run coefficients can be found here: http://www.ditzen.net/Stata/xtdcceInStata.pdf

        Comment


        • #5
          Hi Jan,

          Many thanks for sending the paper. It is highly appreciated. But, what is the difference between your CODE and Mohtades??? In terms of accuracy and efficiently ??? Is there any paper used your Stata Code?? I will read your slides and we will keep in tough if I have question..

          Comment


          • #6
            For clarification of your questions: Kamiar Mohaddes uses xtpmg coded by Edward Blackburn and Mark Frank. xtpmg was designed to estimate the pooled mean group (pmg) estimator. The pmg estimator is based on an error correction model to estimate homogenous long run and heterogeneous short run coefficients. Using the MG option it estimates a mean group model, which relaxes the assumption of homogenous long run coefficients. This is essentially estimating each cross-sectional separately. Using those estimates, the long run coefficients are calculated and then averaged to obtain the mean group estimates.
            xtpmg can only do this for an ECM and not for a level equation (and hence an ARDL model). In addition this is a mean group coefficient model, not a common correlated effects model, thus there is no control for cross-sectional dependence.

            You can use xtpmg with the cce option to to estimate the CS-ARDL estimator. However some further work is required. You need to rewrite the equation, which leads among other things to the model being in first differences. In addition you need to calculate the cross-sectional averages and then add them by hand. Both, rewriting the model and adding the cross sectional averages, can be tricky for a model with many variables and/or many lags of the cross sectional averages.

            xtdcce2 estimates a level equation (an ARDL) and then following Chudik, Mohaddes, Pesaran and Raissi (2016, Advances in Econometrics) calculates the long run coefficients. Thus there is no need to transform the equation into an ECM. It automatically adds the cross-sectional averages, so there is no need to calculate them beforehand and add them by hand. This makes the implementation hopefully easier. Also the CD test is calculated.

            The difference between the two is, xtdcce2 is made for estimating the CS-ARDL model, while xtpmg is made estimating the pooled mean group model. The results will be numerically the same (and this is what I present and show in the slides by reproducing the results from Chudik, Mohaddes, Pesaran and Raissi (2013)). The syntax for xtdcce2 is much easier. Is it more efficient? In terms of statistical or econometric efficiency, it is the same as the standard errors should be the same. In terms of computational efficiency, both programs are made for different estimators. xtdcce2 does a few things in the background xtpmg does not and vice versa.

            The estimation of the long run coefficients (i.e. CS-ARDL and CS-DL) is relatively new in xtdcce2. I made the version publicly available in August. Thus it will take a while until there are papers using it (or at least I hope there will be some....).
            Do you need to use xtdcce2 for estimating an ARDL model, obviously not. You can use xtpmg, ardl - or code the estimator yourself - this is a matter of taste. However I will be able to help with xtdcce2 hence my question if you tried xtdcce2. If it produces an error, I am able to help and finding the problem, with xtpmg this is more difficult at least for me.

            Comment


            • #7
              Hi Jant, Many thanks for your depth explanation. But, why you included 133 number after the command xtdcce2133

              Comment


              • #8
                xtdcce2133 was the working version, so you can ignore the 133 and just call it as xtdcce2.

                Comment


                • #9
                  I already have tried the xtdcc2 by applying Chuik et al's data ...I got this error

                  xtdcce_m_selectindex(): 3499 selectindex() not found

                  <istmt>: - function returned error

                  What is the problem ??

                  Comment


                  • #10
                    Which Stata version do you run?

                    Comment


                    • #11
                      12

                      Comment


                      • #12
                        Hi Jan, does Stata 12 work ???

                        Comment


                        • #13
                          It should work, yes. What happens if you type into your Stata
                          Code:
                          mata c("version")
                          mata (c("version") < 13)
                          Last edited by JanDitzen; 06 Nov 2018, 02:12.

                          Comment


                          • #14
                            Should I type it ??? By the way, did you use first or second difference for dependent variable and explanatory variables

                            Comment


                            • #15
                              . xtdcce2133 d.y dp d.gd d.(dp d.gd) , cr(d.y dp d.gd) cr_lags(0 3 3) /* is the d.y is first or second difference ??

                              Comment

                              Working...
                              X