Announcement

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

  • What's the syntax for panel ARDL model with CCEMG estimator? Should the xtmg command be used?

    Dear all,

    I am learning Stata and trying to figure out how to use the xtpmg command with CCE Mean Group (CCEMG) estimator.


    Recently I read the following paper:
    Benos N., and Karagiannis S., “Inequality and Growth in the United States: Why Physical and Human Capital Matter”, Economic Inquiry, Vol. 56, No. 1, (2018), 572-619.

    This paper runs shor-run and long-run estimates to investigates the relationship between economic growth, inequality and capital by using CCE Mean Group (CCEMG) estimator.

    The model is as below:
    yit=a1,iyit-1+a2,iineqit+a3,i(kit/hit)ineqit+a4(kit/hit)+uir,
    where y, ineq, k and h are panel data variables. The lag length is 4.


    I would like to know all the syntax used to estimate this model, but after reading the Stata help files and some articles regarding how to apply the xtpmg command, I'm still not sure what the syntax should be like.

    Could anyone kindly let me know exactly each syntax I can use in this example to get the results or give some suggestions? I am using Stata 15 on Mac.

    Thanks in advance!

    P.S. The results (CCEMG GMM Long-Run and Short-Run Estimates, along with the Dynamic CCEMG Estimates) in the paper are as below. The syntax I want don't necessarily generate the same type of graphs as below. I put them here just to give an idea that what kind of parameters I'd like to get.





  • #2
    Hi Yang,
    the equation you are mentioning above is a dynamic one, meaning that you would require to use the dynamic CCE estimator. The DCCE estimator is implemented in the xtdcce2 package. xtdcce2 is available on SSC. Assuming that you have variables y, ineq, khineq and kh, the syntax for your equation including each variable as a cross-sectional average, 4 lags of those and no constant is:
    Code:
    xtdcce2 y L.y ineq khineq kh, noconstant cr(y ineq khineq kh) cr_lags(4)
    The option noconstant suppresses the calculation of a constant. With cr() you define the variables added as cross-sectional averages, with cr_lags(4) you set the number of lags of the cross-sectional averages (assuming you want to to this). xtdcce2 can calculate long run coefficients as well (you are mentioning an ARDL, so I am assuming you might be interested in those). In this case you would need to add the variables for the long run relationship and the option lr_options(ardl). For example:
    Code:
    xtdcce2 y , noconstant lr(L.y ineq khineq kh) lr_options(ardl) cr(y ineq khineq kh) cr_lags(4)
    would do the job. For further reference, please see the helpfile for xtdcce2 or the two articles xtdcce2 and long run estimation using xtdcce2.

    As you mention xtmg and xtpmg, a few comments:
    • xtpmg employs the mean group (MG) estimator when using the option mg. However it does not employ the common correlated effects estimator, as it does not add cross-sectional averages.
    • xtmg employs the common correlated effects estimator (CCEMG) and an augmented version with the option aug. However it cannot estimate the dynamic version of the CCEMG estimator, because it adds only contemporaneous lags.

    Comment


    • #3
      Hi Jan,
      Thank you very much for your reply! This is really helpful for my research. Could you please also enlighten me on the questions below:

      1. I tried the first code and it worked well, but when used the code for long term, I got error 3301 as below:
      Code:
      xtdcce2 ΔGDP, noconstant lr(lgdp Δgini khgini kh) lr_options(ardl) cr(ΔGDP Δgini khgini kh) cr_lags(4)
        
      xtdcce_PointByPoint():  3301  subscript invalid
             xtdcce_m_lrcalc():     -  function returned error
                xtdcce_m_reg():     -  function returned error
                       <istmt>:     -  function returned error
      r(3301);
      2. The default confidence interval is 95%, how could I get different confidence intervals such as 90% or 99%?

      3. Could I use xtdcce2 to use the dynamic CCEMG estimator? The benefit of CCEMG is that it can be used regardless of the cross-sectional dependence or nonstationarity, so I wonder if CCE estimator can do the same?

      Comment


      • #4
        Originally posted by Yang Zhou View Post
        Hi Jan,
        Thank you very much for your reply! This is really helpful for my research. Could you please also enlighten me on the questions below:

        1. I tried the first code and it worked well, but when used the code for long term, I got error 3301 as below:
        Code:
        xtdcce2 ΔGDP, noconstant lr(lgdp Δgini khgini kh) lr_options(ardl) cr(ΔGDP Δgini khgini kh) cr_lags(4)
        
        xtdcce_PointByPoint(): 3301 subscript invalid
        xtdcce_m_lrcalc(): - function returned error
        xtdcce_m_reg(): - function returned error
        <istmt>: - function returned error
        r(3301);
        Do you have any multicollinear variables in your model or missing values?
        Can you please try the beta for the next version, see https://janditzen.github.io/xtdcce2/.

        Originally posted by Yang Zhou View Post
        2. The default confidence interval is 95%, how could I get different confidence intervals such as 90% or 99%?

        3. Could I use xtdcce2 to use the dynamic CCEMG estimator? The benefit of CCEMG is that it can be used regardless of the cross-sectional dependence or nonstationarity, so I wonder if CCE estimator can do the same?
        2. You can change the level by changing the level in Stata, see set level #
        3. xtdcce2 automatically uses the dynamic CCEMG estimator, when using the option cr_lags(). See the helpfile for further documentation.

        Hopefully this helps.

        Jan

        Comment


        • #5
          Hi Jan Ditzen, How do I install and use "xtdcce1235". I have been going through the 2019 paper that introduced and used it but I can't install it.
          Thank you for your kind help

          Comment


          • #6
            Hi Daaki Sadat
            the 2019 paper refers to an older version of xtdcce2. The latest available version on SSC is version 2.0 from July 2019. You can either install it using
            Code:
            ssc install xtdcce2
            A beta version of version 2.1 is available on my github page, please see https://janditzen.github.io/xtdcce2/.
            Hope this helps.
            Best,
            Jan

            Comment


            • #7
              Originally posted by JanDitzen View Post
              Hi Daaki Sadat
              the 2019 paper refers to an older version of xtdcce2. The latest available version on SSC is version 2.0 from July 2019. You can either install it using
              Code:
              ssc install xtdcce2
              A beta version of version 2.1 is available on my github page, please see https://janditzen.github.io/xtdcce2/.
              Hope this helps.
              Best,
              Jan
              Thank you for the reply,
              I actually have this installed. But I have been looking at your paper and came across something xtdcce2135. what is the difference between the SSC version 2.0 and 2.1?

              Secondly, does the command change from xtdcce2 to xtdcce2135?


              Click image for larger version

Name:	Screenshot 2020-01-09 at 12.22.42 AM.png
Views:	1
Size:	43.3 KB
ID:	1531230


              How did you come up with the xtdcce2135 command?
              I am so sorry to bother you but i am a novice with stata and DCCE.

              Comment


              • #8
                Daaki Sadat, no problem at all and you are welcome to ask.

                xtdcce2135 was version 1.35 of xtdcce2. The difference between 1.35 and 2.0 was some improvements how collinear variables are handled, which variables are omitted and which inverter used. In addition I added Newey-West type standard errors and fixed T standard errors for the pooled estimator. Version 2.1 has some further improvement and bug fixes (better support for factor variables), in particular with respect to very large panels. It will come with a new sub program which will enhance speed. A summary of the different versions is available here.The command name changes. If it is an final version (at SSC), the program name is xtdcce2. If it is a beta version, the command name is xtdcce2135 or xtdcce221.

                The syntax does not change. So you can just replace the xtdcce2135 with xtdcce221.

                Please let me know if you have any further questions.

                Comment

                Working...
                X