Announcement

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

  • Error with panel data

    I currently deal with the data using fgls. I have a question that is there any problems if "estimated covariances" is equal to"number of groups". My instructor told me that "there is the repeated variables in my data, for example the variable gdp of export and import countries". Please advise. Thank you very much
    Here is the descriptive:
    . sum exportvalue gdp1 gdp2 lpi1 lpi2 elpi1 elpi2 regulatoryquality politicalstability distance commonborder

    Variable | Obs Mean Std. dev. Min Max
    -------------+---------------------------------------------------------
    exportvalue | 540 3.69e+09 7.72e+09 191.739 5.28e+10
    gdp1 | 540 2.56e+11 2.58e+11 9.91e+09 1.12e+12
    gdp2 | 540 2.56e+11 2.58e+11 9.91e+09 1.12e+12
    lpi1 | 540 3.021099 .5229104 2.06725 4.3
    lpi2 | 540 3.021099 .5229104 2.06725 4.3
    -------------+---------------------------------------------------------
    elpi1lpilci | 540 39429.11 53627.14 8418.875 276955.3
    elpi2 | 540 39429.11 53627.14 8418.875 276955.3
    regulatory~y | 540 .0354467 .9635217 -2.244581 2.22636
    politicals~y | 540 -.0812727 .8993196 -2.211743 1.477469
    distance | 540 1637.217 719.7744 314.706 3089.79
    -------------+---------------------------------------------------------
    commonborder | 540 .2444444 .4301558 0 1

    And here is the result of FGLS:

    Cross-sectional time-series FGLS regression

    Coefficients: generalized least squares
    Panels: heteroskedastic
    Correlation: common AR(1) coefficient for all panels (0.7488)

    Estimated covariances = 90 Number of obs = 540
    Estimated autocorrelations = 1 Number of groups = 90
    Estimated coefficients = 9 Time periods = 6
    Wald chi2(8) = 2056.81
    Prob > chi2 = 0.0000

    ------------------------------------------------------------------------------------
    lnexp | Coefficient Std. err. z P>|z| [95% conf. interval]
    -------------------+----------------------------------------------------------------
    lngdpex | 1.11632 .0443255 25.18 0.000 1.029443 1.203196
    lngdpim | .8699424 .0348179 24.99 0.000 .8017005 .9381842
    lndis | -1.235037 .0858691 -14.38 0.000 -1.403338 -1.066737
    lnelpi1 | .4750061 .0458459 10.36 0.000 .3851498 .5648625
    lnelpi2 | .1907061 .0524039 3.64 0.000 .0879963 .2934159
    regulatoryquality | .1550171 .054814 2.83 0.005 .0475837 .2624505
    politicalstability | -.1463815 .0433558 -3.38 0.001 -.2313573 -.0614058
    commonborder | .6490318 .1101282 5.89 0.000 .4331844 .8648792
    _cons | -28.31576 1.436243 -19.72 0.000 -31.13074 -25.50077
    ------------------------------------------------------------------------------------

  • #2
    Willian:
    welcome to this forum.
    Stata is telling you that you have N=90 and T=6.
    That's it.
    I cannot see where the mistake/error lurks here.
    That said, as you're dealing with a N>T panel dataset, you should consider -xtreg- (provided that your regressand is continuous).
    Kind regards,
    Carlo
    (Stata 19.0)

    Comment


    • #3
      Thank you for your information, Carlo.
      I just wonder if it is a problem or not when my database has repeated values.
      Because I examined trade intra-ASEAN, so my database will have repeated value, for example:
      countryex countryim Time lnexp Export value lngdpex GDPex lngdpim GDPim
      Brunei Darussalam Cambodia 2010 11.01614 60848.5 23.28781 1.30E+10 23.2702 1.28E+10
      Cambodia Brunei Darussalam 2010 10.18271 26442 23.2702 1.28E+10 23.28781 1.30E+10
      I conducted FEM, REM and Pool OLS. After testing, FEM is the most suitable model. And my data has autocorrelation and heteroskedasticity issues. How can I deal with it?
      Please help advise. Thanks for your help.

      Comment


      • #4
        Willian:
        if Stata complains about that, you can simply -xtset- your dataset with -panelid- only.
        This trick comes at the cost of making time-series operators, such as lags and leads, unvailable, but still allows you to add -i.timevar- in the right-hand side of your regression equation.
        Use cluster-robust standard errors to deal with both heteroskedasticity and epsilon autocorrelation.
        Kind regards,
        Carlo
        (Stata 19.0)

        Comment


        • #5
          Thank you for your support, Carlo

          Comment

          Working...
          X