Announcement

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

  • Instrumental variable strategy with 2 regressors on panel data

    Dear all,

    I am working on Stata 13.0 with panel data and my linear model has two regressors (x1 and x2 below) which are both endogenous because of reverse causality. The analysis is based on a fixed effects model (hence the reason of -fe- in the code).
    I chose to use the command -xtivreg- for panel data to apply an instrumental variable technique, with one IV (iv1 and iv2 below) per each regressor - I have done some research on the topic and it seems to be both possible and sensible, but if you have comments on this point, please feel free to offer your suggestions.

    My code, where x1, x2 are the endogenous variables and regressors; y independent variable; iv1 and iv2 respectively the instruments for the regressor x1 and regressor x2; c1, c2, c3, c4 the control variables; is:
    Code:
    .
    . xtset
           panel variable:  CountryMark (strongly balanced)
            time variable:  Year, 2000 to 2014
                    delta:  1 year
    
    . xtivreg y c1 c2 c3 c4 c5 c6 (x1 x2 = iv1 iv2), fe first
    
    First-stage within regression
    
    Fixed-effects (within) regression               Number of obs      =        83
    Group variable: CountryMark                     Number of groups   =        16
    
    R-sq:  within  = 0.8263                         Obs per group: min =         1
           between = 0.6704                                        avg =       5.2
           overall = 0.4224                                        max =         8
    
                                                    F(7,60)            =     40.77
    corr(u_i, Xb)  = -0.9921                        Prob > F           =    0.0000
    
    -------------------------------------------------------------------------------------------
    x1 |      Coef.   Std. Err.      t    P>|t|     [95% Conf. Interval]
    --------------------------+----------------------------------------------------------------
    c1 |   3.991628   2.179243     1.83   0.072    -.3675069    8.350764
    c2 |   1.512567   1.751205     0.86   0.391    -1.990365    5.015499
    c3 |  -9.588328   1.767561    -5.42   0.000    -13.12398    -6.05268
    c4 |  -4.564994   2.565139    -1.78   0.080    -9.696035     .566048
    iv1  |  33.40758   9.801486     3.41   0.001     13.80169    53.01347
    iv2 |   .0842356   .3823848     0.22   0.826    -.6806478     .849119
    _cons |   405.9367   99.26616     4.09   0.000     207.3748    604.4986
    --------------------------+----------------------------------------------------------------
                      sigma_u |  230.14575
                      sigma_e |  13.768958
                          rho |  .99643348   (fraction of variance due to u_i)
    -------------------------------------------------------------------------------------------
    F test that all u_i=0:     F(15, 60) =    13.24              Prob > F = 0.0000
    
    First-stage within regression
    
    Fixed-effects (within) regression               Number of obs      =        83
    Group variable: CountryMark                     Number of groups   =        16
    
    R-sq:  within  = 0.3931                         Obs per group: min =         1
           between = 0.0089                                        avg =       5.2
           overall = 0.0067                                        max =         8
    
                                                    F(7,60)            =      5.55
    corr(u_i, Xb)  = -0.2638                        Prob > F           =    0.0001
    
    -------------------------------------------------------------------------------------------
    x2 |      Coef.   Std. Err.      t    P>|t|     [95% Conf. Interval]
    --------------------------+----------------------------------------------------------------
    c1 |   .8159419   .2826313     2.89   0.005     .2505951    1.381289
    c2 |   .1652445    .285271     0.58   0.565    -.4053825    .7358715
    c3 |  -1.200964    .413994    -2.90   0.005    -2.029075   -.3728521
    c4  |   .0002438   .0001594     1.53   0.131    -.0000749    .0005626
    iv1 |   33.40758   9.801486     3.41   0.001     13.80169    53.01347
    iv2 |  -.0036747    .061714    -0.06   0.953    -.1271211    .1197717
    _cons |   5.465016   16.02081     0.34   0.734    -26.58137     37.5114
    --------------------------+----------------------------------------------------------------
                      sigma_u |  13.100655
                      sigma_e |  2.2222059
                          rho |  .97203189   (fraction of variance due to u_i)
    -------------------------------------------------------------------------------------------
    F test that all u_i=0:     F(15, 60) =    56.09              Prob > F = 0.0000
    
    Fixed-effects (within) IV regression         Number of obs      =           83
    Group variable: CountryMark                  Number of groups   =           16
    
    R-sq:  within  =      .                      Obs per group: min =            1
           between = 0.5223                                     avg =          5.2
           overall = 0.6442                                     max =            8
    
                                                 Wald chi2(7)       =       308.66
    corr(u_i, Xb)  = -0.9891                     Prob > chi2        =       0.0000
    
    -------------------------------------------------------------------------------------------
    y |      Coef.   Std. Err.      z    P>|z|     [95% Conf. Interval]
    --------------------------+----------------------------------------------------------------
    x1 |  -13.34982   95.60653    -0.14   0.889    -200.7352    174.0355
    x2 |   259.4363   2165.715     0.12   0.905    -3985.286    4504.159
    c1 |  -96.37982   979.8331    -0.10   0.922    -2016.817    1824.058
    c2 |  -171.2541   1636.062    -0.10   0.917    -3377.877    3035.369
    c3 |  -203.7811   1278.566    -0.16   0.873    -2709.725    2302.163
    c4 |   249.9043   2121.014     0.12   0.906    -3907.208    4407.016
    _cons |   6319.568   29518.49     0.21   0.830    -51535.61    64174.75
    --------------------------+----------------------------------------------------------------
                      sigma_u |  5729.8217
                      sigma_e |  575.43353
                          rho |  .99001496   (fraction of variance due to u_i)
    -------------------------------------------------------------------------------------------
    F  test that all u_i=0:     F(15,60) =     2.47           Prob > F    = 0.0070
    -------------------------------------------------------------------------------------------
    Instrumented:   x1 x2
    Instruments:    c1 c2 c3 c4 iv1 iv2
    -------------------------------------------------------------------------------------------


    The thing I do not understand is why, in the last table, Stata says that I instrumented -x1 and x2 (correct) with c1 c2 c3 c4 iv1 iv2 (too many! the instruments are only iv1 and iv2). So maybe I am doing something wrong on the syntax side; but after following the help document and searching for an answer, I am still clueless. Besides, I found a very limited number of models with two regressors which are both instrumented.

    Don't bother looking at the numerical results - they are temporary.

    Thank you in advance for your precious help!
    Last edited by Ambra Cortesi; 24 Apr 2017, 15:42.

  • #2
    As an additional question, I would like to know if somebody can suggest a way to instrument x1 only with iv1 and x2 only with iv2, because from the first stage regression, it seems that each of the regressors is instrumented by both iv1 and iv2. Thanks.

    Comment


    • #3
      Endogenous regressors are always instrumented by all exogenous regressors (that serve as instruments for themselves) and all instruments. While you might allocate specific IVs to specific regressors based on theoretical reasons, for the econometric part this does not matter. All regressors are instrumented by all instruments. Please consult any econometrics textbook of your choice for further details.
      https://twitter.com/Kripfganz

      Comment

      Working...
      X