Announcement

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

  • csdid : csdid does not return entire group ATTs when I include covariates

    when I simply run csdid,

    qui csdid y_var , ivar(statefip) time(t_ym) gvar(pol_ym) notyet long2
    csdid_estat group



    the results return all 10 groups.


    . csdid_estat group
    ATT by group
    ------------------------------------------------------------------------------
    | Coefficient Std. err. z P>|z| [95% conf. interval]
    -------------+----------------------------------------------------------------
    GAverage | 39.75624 1.970523 20.18 0.000 35.89408 43.61839
    G534 | -3.181626 3.323437 -0.96 0.338 -9.695444 3.332192
    G588 | 11.59253 4.209699 2.75 0.006 3.341677 19.84339
    G696 | 28.24867 5.484564 5.15 0.000 17.49912 38.99822
    G702 | -13.40629 8.040015 -1.67 0.095 -29.16443 2.351854
    G720 | 31.85622 16.74251 1.90 0.057 -.958487 64.67093
    G726 | -26.01383 16.64317 -1.56 0.118 -58.63385 6.606177
    G732 | 43.15997 15.62937 2.76 0.006 12.52696 73.79298
    G744 | 19.30807 1.52619 12.65 0.000 16.31679 22.29935
    G764 | 266.2424 6.36e-14 4.2e+15 0.000 266.2424 266.2424
    ------------------------------------------------------------------------------



    However, when I include covariates, it returns some of the groups and the number of groups got returned differs by which covariates I include.

    For example, when I include cov1
    qui csdid y_var cov1 , ivar(statefip) time(t_ym) gvar(pol_ym) notyet long2
    csdid_estat group

    returns only 5 groups

    ATT by group
    ------------------------------------------------------------------------------
    | Coefficient Std. err. z P>|z| [95% conf. interval]
    -------------+----------------------------------------------------------------
    GAverage | .2577446 5.208761 0.05 0.961 -9.95124 10.46673
    G534 | -6.54916 3.593409 -1.82 0.068 -13.59211 .4937928
    G588 | 10.75291 1.911706 5.62 0.000 7.006041 14.49979
    G696 | 15.31813 2.476017 6.19 0.000 10.46523 20.17104
    G702 | -11.3719 5.898125 -1.93 0.054 -22.93201 .1882136
    G720 | -6.861267 21.82422 -0.31 0.753 -49.63596 35.91342
    ------------------------------------------------------------------------------



    and when I include cov2
    qui csdid y_var cov2 , ivar(statefip) time(t_ym) gvar(pol_ym) notyet long2
    csdid_estat group

    returns only 2 groups

    ATT by group
    ------------------------------------------------------------------------------
    | Coefficient Std. err. z P>|z| [95% conf. interval]
    -------------+----------------------------------------------------------------
    GAverage | -2.229343 1.138762 -1.96 0.050 -4.461275 .0025895
    G588 | 2.758401 2.317998 1.19 0.234 -1.78479 7.301593
    G702 | -7.217087 1.312828 -5.50 0.000 -9.790183 -4.643991
    ------------------------------------------------------------------------------




    Is there any one who knows how I can get the all 10 groups even though I include covariates as much as I want?
    Last edited by Nathan Choi; 01 Mar 2024, 16:33.

  • #2
    I just checked All ATTs, and I learned that all ATTs are calculated, but weights are calculated only for the groups that returned. Why is this happening...

    Comment


    • #3
      Can you post what you get with ereturn display ?
      there may be a hidden bug you just happen to fins

      Comment

      Working...
      X