Announcement

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

  • Help with xtreg, time fixed effects, local authority fixed effects

    Hi,
    I am new to Stata and therefore would appreciate some help with actually running my panel regression.
    Below is my data. I have already done xtset and generated qdate from that.
    Code:
    * Example generated by -dataex-. To install: ssc install dataex
    clear
    input str43 name float acode int year byte quarter float(qdate compost loginc logpopden loghhsize) long(md11 md12 md31 md32 md33) float(comavg wasteavg)
    "Adur District Council"        7000223 2014 3 218 10.892403 9.899881   2.678072 .8671005 1 1 0 1 0 0  0
    "Adur District Council"        7000223 2012 4 211  5.109999 9.845911    2.65858 .8586616 1 1 0 1 0 0  0
    "Adur District Council"        7000223 2013 3 214  9.623345 9.886138   2.668824 .8628899 1 1 0 1 0 0  0
    "Adur District Council"        7000223 2014 4 219  6.039579 9.899881   2.678072 .8671005 1 1 0 1 0 0  0
    "Adur District Council"        7000223 2012 2 209  9.733083 9.845911    2.65858 .8586616 1 1 0 1 0 0  0
    "Adur District Council"        7000223 2012 1 208  3.635365 9.845911   2.663471 .8586616 1 1 0 1 0 0  0
    "Adur District Council"        7000223 2015 2 221 12.008673  9.97376  2.6887314 .8671005 1 1 0 1 0 0  0
    "Adur District Council"        7000223 2016 4 227  6.988868  9.97711  2.6927335 .8712934 1 1 0 1 0 0  0
    "Adur District Council"        7000223 2013 2 213 11.354862 9.886138   2.668824 .8628899 1 1 0 1 0 0  0
    "Adur District Council"        7000223 2016 1 224 4.0117025  9.97711  2.6927335 .8712934 1 1 0 1 0 0  0
    "Adur District Council"        7000223 2014 2 217  13.06053 9.899881   2.668824 .8671005 1 1 0 1 0 0  0
    "Adur District Council"        7000223 2013 4 215  6.429264 9.886138   2.668824 .8628899 1 1 0 1 0 0  0
    "Adur District Council"        7000223 2015 4 223  6.273902  9.97376  2.6887314 .8671005 1 1 0 1 0 0  0
    "Adur District Council"        7000223 2015 3 222 10.610566  9.97376  2.6887314 .8671005 1 1 0 1 0 0  0
    "Adur District Council"        7000223 2014 1 216 4.6309547 9.899881   2.678072 .8671005 1 1 0 1 0 0  0
    "Adur District Council"        7000223 2016 2 225 13.037227  9.97711  2.6927335 .8712934 1 1 0 1 0 0  0
    "Adur District Council"        7000223 2016 3 226 12.508617  9.97711  2.6927335 .8712934 1 1 0 1 0 0  0
    "Adur District Council"        7000223 2012 3 210  10.98731 9.845911    2.65858 .8586616 1 1 0 1 0 0  0
    "Adur District Council"        7000223 2015 1 220  3.851408  9.97376  2.6887314 .8671005 1 1 0 1 0 0  0
    "Adur District Council"        7000223 2013 1 212  2.391451 9.886138   2.668824 .8628899 1 1 0 1 0 0  0
    "Allerdale Borough Council"    7000026 2014 1 216 2.9364595 9.709964  -.2984061 .8671005 1 1 0 0 0 1  0
    "Allerdale Borough Council"    7000026 2016 1 224  7.628589 9.771498 -.29437107 .8712934 1 1 0 0 0 1  0
    "Allerdale Borough Council"    7000026 2012 3 210   23.2185 9.676775 -.29705927 .8586616 1 1 0 0 0 1  0
    "Allerdale Borough Council"    7000026 2016 4 227 13.765405 9.771498 -.29437107 .8712934 1 1 0 0 0 1  0
    "Allerdale Borough Council"    7000026 2016 3 226 27.984756 9.771498 -.29437107 .8712934 1 1 0 0 0 1  0
    "Allerdale Borough Council"    7000026 2013 4 215 12.774913 9.691964  -.2984061 .8628899 1 1 0 0 0 1  0
    "Allerdale Borough Council"    7000026 2014 4 219 13.436963 9.709964  -.2984061 .8671005 1 1 0 0 0 1  0
    "Allerdale Borough Council"    7000026 2015 4 223  11.30833 9.758347 -.29571423 .8671005 1 1 0 0 0 1  0
    "Allerdale Borough Council"    7000026 2013 1 212  6.428598 9.691964  -.2984061 .8628899 1 1 0 0 0 1  0
    "Allerdale Borough Council"    7000026 2015 2 221  23.62139 9.758347 -.29571423 .8671005 1 1 0 0 0 1  0
    "Allerdale Borough Council"    7000026 2014 3 218  24.60719 9.709964  -.2984061 .8671005 1 1 0 0 0 1  0
    "Allerdale Borough Council"    7000026 2012 2 209  23.02372 9.676775 -.29705927 .8586616 1 1 0 0 0 1  0
    "Allerdale Borough Council"    7000026 2014 2 217 29.104996 9.709964  -.2984061 .8671005 1 1 0 0 0 1  0
    "Allerdale Borough Council"    7000026 2015 1 220  6.617072 9.758347 -.29571423 .8671005 1 1 0 0 0 1  0
    "Allerdale Borough Council"    7000026 2012 4 211 11.482567 9.676775 -.29705927 .8586616 1 1 0 0 0 1  0
    "Allerdale Borough Council"    7000026 2013 2 213 21.339706 9.691964  -.2984061 .8628899 1 1 0 0 0 1  0
    "Allerdale Borough Council"    7000026 2012 1 208 17.704374 9.676775  -.3202052 .8586616 1 1 0 0 0 1  0
    "Allerdale Borough Council"    7000026 2015 3 222 25.802023 9.758347 -.29571423 .8671005 1 1 0 0 0 1  0
    "Allerdale Borough Council"    7000026 2013 3 214  27.43951 9.691964  -.2984061 .8628899 1 1 0 0 0 1  0
    "Allerdale Borough Council"    7000026 2016 2 225  22.63528 9.771498 -.29437107 .8712934 1 1 0 0 0 1  0
    "Amber Valley Borough Council" 7000032 2012 2 209  5.100012 9.700024  1.5288783 .8586616 1 1 0 0 0 1  1
    "Amber Valley Borough Council" 7000032 2015 4 223    6.8863 9.819834  1.5407307 .8671005 1 1 0 0 0 1  1
    "Amber Valley Borough Council" 7000032 2014 3 218 12.400318 9.749112  1.5370823 .8671005 1 1 0 0 0 1  1
    "Amber Valley Borough Council" 7000032 2013 2 213  11.47245 9.740204   1.531044 .8628899 1 1 0 0 0 1  1
    "Amber Valley Borough Council" 7000032 2016 4 227  6.131042 9.838789  1.5415872 .8712934 1 1 0 0 0 1 .8
    "Amber Valley Borough Council" 7000032 2013 1 212  .5841476 9.740204   1.531044 .8628899 1 1 0 0 0 1  1
    "Amber Valley Borough Council" 7000032 2014 1 216   3.47621 9.749112  1.5370823 .8671005 1 1 0 0 0 1  1
    "Amber Valley Borough Council" 7000032 2012 4 211 2.7343905 9.700024  1.5288783 .8586616 1 1 0 0 0 1  1
    "Amber Valley Borough Council" 7000032 2014 4 219   6.58514 9.749112  1.5370823 .8671005 1 1 0 0 0 1  1
    "Amber Valley Borough Council" 7000032 2016 3 226 13.686172 9.838789  1.5415872 .8712934 1 1 0 0 0 1 .8
    "Amber Valley Borough Council" 7000032 2016 1 224  3.255951 9.838789  1.5415872 .8712934 1 1 0 0 0 1 .8
    "Amber Valley Borough Council" 7000032 2013 3 214 13.181116 9.740204   1.531044 .8628899 1 1 0 0 0 1  1
    "Amber Valley Borough Council" 7000032 2015 3 222  12.70684 9.819834  1.5407307 .8671005 1 1 0 0 0 1  1
    "Amber Valley Borough Council" 7000032 2014 2 217 14.295996 9.749112  1.5370823 .8671005 1 1 0 0 0 1  1
    "Amber Valley Borough Council" 7000032 2016 2 225  12.65073 9.838789  1.5415872 .8712934 1 1 0 0 0 1 .8
    "Amber Valley Borough Council" 7000032 2012 3 210  5.702137 9.700024  1.5288783 .8586616 1 1 0 0 0 1  1
    "Amber Valley Borough Council" 7000032 2013 4 215  7.264445 9.740204   1.531044 .8628899 1 1 0 0 0 1  1
    "Amber Valley Borough Council" 7000032 2015 2 221 12.903378 9.819834  1.5407307 .8671005 1 1 0 0 0 1  1
    "Amber Valley Borough Council" 7000032 2012 1 208  1.366725 9.700024  1.5214807 .8586616 1 1 0 0 0 1  1
    "Amber Valley Borough Council" 7000032 2015 1 220 2.8631465 9.819834  1.5407307 .8671005 1 1 0 0 0 1  1
    "Arun District Council"        7000224 2014 4 219 10.163612 9.865993  1.9205923 .8671005 0 0 0 0 0 1  0
    "Arun District Council"        7000224 2012 3 210 14.908836 9.820486   1.900614 .8586616 0 0 0 0 0 1  0
    "Arun District Council"        7000224 2013 4 215 10.379933 9.860788   1.911171 .8628899 0 0 0 0 0 1  0
    "Arun District Council"        7000224 2013 2 213 14.527653 9.860788   1.911171 .8628899 0 0 0 0 0 1  0
    "Arun District Council"        7000224 2015 4 223 10.780918 9.936874  1.9309415 .8671005 0 0 0 0 0 1  0
    "Arun District Council"        7000224 2016 3 226 15.996178 9.939385   1.939461 .8712934 0 0 0 0 0 1  0
    "Arun District Council"        7000224 2013 1 212  3.751499 9.860788   1.911171 .8628899 0 0 0 0 0 1  0
    "Arun District Council"        7000224 2012 1 208  6.256315 9.820486  1.9059806 .8586616 0 0 0 0 0 1  0
    "Arun District Council"        7000224 2016 1 224  7.261099 9.939385   1.939461 .8712934 0 0 0 0 0 1  0
    "Arun District Council"        7000224 2015 3 222 15.054287 9.936874  1.9309415 .8671005 0 0 0 0 0 1  0
    "Arun District Council"        7000224 2012 2 209 13.356665 9.820486   1.900614 .8586616 0 0 0 0 0 1  0
    "Arun District Council"        7000224 2014 2 217 17.668224 9.865993   1.911171 .8671005 0 0 0 0 0 1  0
    "Arun District Council"        7000224 2016 2 225 17.891514 9.939385   1.939461 .8712934 0 0 0 0 0 1  0
    "Arun District Council"        7000224 2014 1 216  7.029479 9.865993  1.9205923 .8671005 0 0 0 0 0 1  0
    "Arun District Council"        7000224 2016 4 227 10.966786 9.939385   1.939461 .8712934 0 0 0 0 0 1  0
    "Arun District Council"        7000224 2014 3 218  14.52263 9.865993  1.9205923 .8671005 0 0 0 0 0 1  0
    "Arun District Council"        7000224 2012 4 211  8.587595 9.820486   1.900614 .8586616 0 0 0 0 0 1  0
    "Arun District Council"        7000224 2013 3 214 13.281113 9.860788   1.911171 .8628899 0 0 0 0 0 1  0
    "Arun District Council"        7000224 2015 1 220  6.921752 9.936874  1.9309415 .8671005 0 0 0 0 0 1  0
    "Arun District Council"        7000224 2015 2 221 16.799276 9.936874  1.9309415 .8671005 0 0 0 0 0 1  0
    "Ashfield District Council"    7000170 2016 1 224 1.9273784 9.705341  2.4285126 .8712934 1 1 0 0 0 1  1
    "Ashfield District Council"    7000170 2012 2 209 11.912817 9.593151   2.394982 .8586616 1 1 0 0 0 .  1
    "Ashfield District Council"    7000170 2016 2 225  26.37377 9.705341  2.4285126 .8712934 1 1 0 0 0 1  1
    "Ashfield District Council"    7000170 2013 4 215   7.10045 9.608781   2.400256 .8628899 1 1 0 0 0 1  1
    "Ashfield District Council"    7000170 2015 1 220 1.9483192 9.701432  2.4198346 .8671005 1 1 0 0 0 1  1
    "Ashfield District Council"    7000170 2014 3 218 13.430163 9.641084  2.4119775 .8671005 1 1 0 0 0 1  1
    "Ashfield District Council"    7000170 2013 1 212  .9463254 9.608781   2.400256 .8628899 1 1 0 0 0 1  1
    "Ashfield District Council"    7000170 2012 3 210  13.49746 9.593151   2.394982 .8586616 1 1 0 0 0 .  1
    "Ashfield District Council"    7000170 2013 3 214 14.160374 9.608781   2.400256 .8628899 1 1 0 0 0 1  1
    "Ashfield District Council"    7000170 2015 3 222 14.858505 9.701432  2.4198346 .8671005 1 1 0 0 0 1  1
    "Ashfield District Council"    7000170 2016 3 226  28.49253 9.705341  2.4285126 .8712934 1 1 0 0 0 1  1
    "Ashfield District Council"    7000170 2015 4 223  8.768002 9.701432  2.4198346 .8671005 1 1 0 0 0 1  1
    "Ashfield District Council"    7000170 2014 2 217 14.909673 9.641084  2.4119775 .8671005 1 1 0 0 0 1  1
    "Ashfield District Council"    7000170 2015 2 221   14.8295 9.701432  2.4198346 .8671005 1 1 0 0 0 1  1
    "Ashfield District Council"    7000170 2012 1 208  2.435588 9.593151  2.3737888 .8586616 1 1 0 0 0 .  1
    "Ashfield District Council"    7000170 2012 4 211  5.795621 9.593151   2.394982 .8586616 1 1 0 0 0 .  1
    "Ashfield District Council"    7000170 2014 1 216 2.2574463 9.641084  2.4119775 .8671005 1 1 0 0 0 1  1
    "Ashfield District Council"    7000170 2014 4 219   7.14231 9.641084  2.4119775 .8671005 1 1 0 0 0 1  1
    "Ashfield District Council"    7000170 2016 4 227 14.496334 9.705341  2.4285126 .8712934 1 1 0 0 0 1  1
    "Ashfield District Council"    7000170 2013 2 213 12.329373 9.608781   2.400256 .8628899 1 1 0 0 0 1  1
    end
    format %tq qdate
    I would like to regress the compost rate on income, population density, household size, methods of waste and compost collection(md) and the frequency of collection of compost and waste (comavg &wasteavg). I want variables to capture time fixed effects and local authority fixed effects. Is the following command suitable for this, or how do I include these fixed effects?

    xtreg compost loginc logpopden loghhsize md11 md12 md31 md32 md33 wasteavg comavg

    Thank You!!

  • #2
    Darcy:
    some comments about you excerpt/example (by the way: thanks for using -dataex-):
    - your -panelid- is in -string- format (that -xtset- doesn't allow);
    - as you can see from the following rersults, you have some collinearity issues with your data (I'm under the impresion that you have predictors that measure essentially the same thing from different perspective):
    Code:
    . encode name, g(name_2)
    
    . xtset name_2 qdate
           panel variable:  name_2 (strongly balanced)
            time variable:  qdate, 2012q1 to 2016q4
                    delta:  1 quarter
    
    . xtreg compost loginc logpopden loghhsize md11 md12 md31 md32 md33 wasteavg comavg i.year i.acode
    note: md12 omitted because of collinearity
    note: md31 omitted because of collinearity
    note: md33 omitted because of collinearity
    note: comavg omitted because of collinearity
    note: 2016.year omitted because of collinearity
    note: 7000223.acode omitted because of collinearity
    note: 7000224.acode omitted because of collinearity
    
    Random-effects GLS regression                   Number of obs     =         96
    Group variable: name_2                          Number of groups  =          5
    
    R-sq:                                           Obs per group:
         within  = 0.0470                                         min =         16
         between = 1.0000                                         avg =       19.2
         overall = 0.3122                                         max =         20
    
                                                    Wald chi2(11)     =      38.13
    corr(u_i, X)   = 0 (assumed)                    Prob > chi2       =     0.0001
    
    ------------------------------------------------------------------------------
         compost |      Coef.   Std. Err.      z    P>|z|     [95% Conf. Interval]
    -------------+----------------------------------------------------------------
          loginc |   85.57483   117.2528     0.73   0.465    -144.2365    315.3862
       logpopden |  -21.40776    151.398    -0.14   0.888    -318.1424    275.3269
       loghhsize |  -467.4829   970.8674    -0.48   0.630    -2370.348    1435.382
            md11 |  -27.70277   326.0937    -0.08   0.932    -666.8347    611.4291
            md12 |          0  (omitted)
            md31 |          0  (omitted)
            md32 |   37.53225   438.7121     0.09   0.932    -822.3277    897.3922
            md33 |          0  (omitted)
        wasteavg |   15.46251   24.37861     0.63   0.526    -32.31869    63.24372
          comavg |          0  (omitted)
                 |
            year |
           2013  |  -.3970835   1.938762    -0.20   0.838    -4.196987     3.40282
           2014  |   1.461096   3.709928     0.39   0.694     -5.81023    8.732421
           2015  |  -4.075915   4.202581    -0.97   0.332    -12.31282    4.160993
           2016  |          0  (omitted)
                 |
           acode |
        7000032  |   10.42762   263.4831     0.04   0.968    -505.9898     526.845
        7000170  |   42.33788   402.7024     0.11   0.916    -746.9443      831.62
        7000223  |          0  (omitted)
        7000224  |          0  (omitted)
                 |
           _cons |  -387.7999   260.8881    -1.49   0.137    -899.1313    123.5314
    -------------+----------------------------------------------------------------
         sigma_u |          0
         sigma_e |  6.0824524
             rho |          0   (fraction of variance due to u_i)
    ------------------------------------------------------------------------------
    
    . xttest0
    
    Breusch and Pagan Lagrangian multiplier test for random effects
    
            compost[name_2,t] = Xb + u[name_2] + e[name_2,t]
    
            Estimated results:
                             |       Var     sd = sqrt(Var)
                    ---------+-----------------------------
                     compost |   47.56243       6.896552
                           e |   36.99623       6.082452
                           u |          0              0
    
            Test:   Var(u) = 0
                                 chibar2(01) =     0.00
                              Prob > chibar2 =   1.0000
    Provided that the following results might be due to data example you posted:

    - between R-sq=1 reports overfitting;
    -possibly due to overfitting alone, xttest0- outcome tells you that you basically do not have random effect and should switch from -xtreg. to pooled -regress-.
    Kind regards,
    Carlo
    (Stata 19.0)

    Comment


    • #3
      Hi Carlo,

      Yes I only provided a snippet of my data. The panel ID is acode which in my data I thought was numeric? The collinearity I am aware of I just wanted to check the estimation was ok. Why have you added
      i.year i.acode Are these the time and state fixed effects. What does xttest test for? What is the different with pooled regress? Sorry this is all new to me!

      Comment


      • #4
        Darcy:
        - -i.year- and -i-acode- are time and (if -acode- is the state code), state fixed effects;
        - -xttest0- tests for random effect; if the test reaches statitical significance, it's wise to use -hausman- to investigate whether -fe- or -re- specification is the way to go;
        - if there's no evidence of panelwise effect, pooled OLS is the way to go.

        If you have more concerns about these and other panel-related topics, I woud recommend you to take a look at any decent panel data econometrics textbook.
        Stata users are usually fond of https://www.stata.com/bookstore/micr...metrics-stata/, but you can find many more references in -xtreg- entry of Stata .pdf manual.
        Kind regards,
        Carlo
        (Stata 19.0)

        Comment


        • #5
          Thank you very much that is really helpful!!
          Kind Regards

          Darcy

          Comment


          • #6
            Originally posted by Carlo Lazzaro View Post
            Darcy:
            - -i.year- and -i-acode- are time and (if -acode- is the state code), state fixed effects;
            - -xttest0- tests for random effect; if the test reaches statitical significance, it's wise to use -hausman- to investigate whether -fe- or -re- specification is the way to go;
            - if there's no evidence of panelwise effect, pooled OLS is the way to go.

            If you have more concerns about these and other panel-related topics, I woud recommend you to take a look at any decent panel data econometrics textbook.
            Stata users are usually fond of https://www.stata.com/bookstore/micr...metrics-stata/, but you can find many more references in -xtreg- entry of Stata .pdf manual.
            if xttest0 give the result that

            Prob > chibar2 = x
            with x < 0.05 then i should use rem model, right?

            Comment


            • #7
              Lenny:
              not quite.
              If the -xttest0- outcome is statistical significant, you should test via -hausman- which specification (ie, -fe- or -re-) fits your data better.
              Kind regards,
              Carlo
              (Stata 19.0)

              Comment


              • #8
                Now my output looks like this. What is the intuition behind the qdate coefficients? Have I controlled for factors that are constant over time and included local authority fixed effects?

                Thanks!

                eststo: xtreg recycling loginc logpopden loghhsize md11 md12 md13 md14 md15 md16 md1
                > 7 md18 md19 md20 md21 md22 md23 md24 md25 md26 md27 md28 md29 md291 wasteavg dryavg
                > i.qdate, fe vce(cluster acode)
                note: 227.qdate omitted because of collinearity

                Fixed-effects (within) regression Number of obs = 5,862
                Group variable: acode Number of groups = 311

                R-sq: Obs per group:
                within = 0.3738 min = 4
                between = 0.0537 avg = 18.8
                overall = 0.0751 max = 20

                F(43,310) = 40.88
                corr(u_i, Xb) = -0.7887 Prob > F = 0.0000

                (Std. Err. adjusted for 311 clusters in acode)
                ------------------------------------------------------------------------------
                | Robust
                recycling | Coef. Std. Err. t P>|t| [95% Conf. Interval]
                -------------+----------------------------------------------------------------
                loginc | 6.702137 6.054236 1.11 0.269 -5.210455 18.61473
                logpopden | -4.675251 2.264116 -2.06 0.040 -9.130229 -.2202723
                loghhsize | -272.0538 57.04498 -4.77 0.000 -384.2981 -159.8094
                md11 | .3351867 .481311 0.70 0.487 -.6118629 1.282236
                md12 | -.6399805 .40853 -1.57 0.118 -1.443823 .1638619
                md13 | -.9050849 .5412118 -1.67 0.095 -1.969998 .1598282
                md14 | -.0980255 .4730273 -0.21 0.836 -1.028776 .8327247
                md15 | .566539 .5845778 0.97 0.333 -.5837032 1.716781
                md16 | .1718006 .7147628 0.24 0.810 -1.234599 1.578201
                md17 | -.2656376 .3883305 -0.68 0.494 -1.029735 .4984594
                md18 | -.0322301 .6249675 -0.05 0.959 -1.261945 1.197485
                md19 | .0459583 .4569531 0.10 0.920 -.8531636 .9450801
                md20 | -1.562761 .5143033 -3.04 0.003 -2.574728 -.5507943
                md21 | -.8982675 .4958624 -1.81 0.071 -1.873949 .0774141
                md22 | -1.265484 .5063549 -2.50 0.013 -2.261811 -.2691565
                md23 | .1601407 .5280048 0.30 0.762 -.8787858 1.199067
                md24 | .3291697 .4134302 0.80 0.427 -.4843146 1.142654
                md25 | .129006 .9201405 0.14 0.889 -1.681505 1.939517
                md26 | .5460655 .3869045 1.41 0.159 -.2152256 1.307357
                md27 | 1.418712 .3757942 3.78 0.000 .6792817 2.158142
                md28 | .3815361 .2994692 1.27 0.204 -.2077133 .9707855
                md29 | .0883002 .6933891 0.13 0.899 -1.276044 1.452645
                md291 | .4481236 .3742229 1.20 0.232 -.2882145 1.184462
                wasteavg | 1.426658 .5686578 2.51 0.013 .307741 2.545575
                dryavg | -.6591199 .648601 -1.02 0.310 -1.935337 .6170972
                |
                qdate |
                209 | -3.654327 .1805906 -20.24 0.000 -4.009665 -3.298988
                210 | -3.956836 .2001155 -19.77 0.000 -4.350592 -3.563079
                211 | -1.601449 .199668 -8.02 0.000 -1.994325 -1.208574
                212 | 1.820826 .2079356 8.76 0.000 1.411682 2.229969
                213 | -2.733047 .1985251 -13.77 0.000 -3.123674 -2.34242
                214 | -2.188786 .1941851 -11.27 0.000 -2.570873 -1.806698
                215 | -.9890916 .2116455 -4.67 0.000 -1.405535 -.5726482
                216 | 2.236385 .244299 9.15 0.000 1.755692 2.717079
                217 | -2.530845 .23813 -10.63 0.000 -2.9994 -2.06229
                218 | -1.523505 .2330477 -6.54 0.000 -1.98206 -1.064949
                219 | .1278155 .2222644 0.58 0.566 -.3095221 .5651531
                220 | 2.517964 .2909664 8.65 0.000 1.945445 3.090482
                221 | -2.828811 .2566465 -11.02 0.000 -3.333801 -2.323822
                222 | -2.548703 .2496457 -10.21 0.000 -3.039917 -2.057488
                223 | -1.170437 .2337115 -5.01 0.000 -1.630299 -.7105755
                224 | 2.327288 .1785427 13.03 0.000 1.975979 2.678597
                225 | -1.723372 .1225738 -14.06 0.000 -1.964554 -1.48219
                226 | -1.734682 .1149703 -15.09 0.000 -1.960903 -1.508461
                227 | 0 (omitted)
                |
                _cons | 202.8288 22.60668 8.97 0.000 158.3469 247.3108
                -------------+----------------------------------------------------------------
                sigma_u | 6.8699199
                sigma_e | 2.5461858
                rho | .87922504 (fraction of variance due to u_i)
                -----------------------------------------------------------------

                Comment


                • #9
                  Darcy:
                  technically speaking, the -i.time- predictor captures the time-series variation of the regressand (ie, how the regressand changes within each panel as time goes by, when adjusted for the remaining predictors) (see https://www.statalist.org/forums/for...-fixed-effects [especially #3]). The -i.time- is often loosely defines as time -fixed effect-.
                  Hence, in your model the fixed effect refers to your -panelid- only
                  Obviously, what you have done may be perfectly in line with your research goal.
                  As per your query, you can test whether (as it seems) -qdate- are jointly significant.
                  As an aside, if you want to consider both -panelid- and -i.time- fixed effects, you may want to consider the community-contributed -reghdfe- command.
                  Kind regards,
                  Carlo
                  (Stata 19.0)

                  Comment

                  Working...
                  X