Announcement

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

  • Variance-covariance matrix (sigma) - csdid

    Hello everyone,

    I am doing DID with multiple periods using csdid, after that, I will do power calculations and visualization for pre-trends tests by Jonathan Roth. For this analysis, I require:

    1. coefficients (beta)
    2. the variance-covariance matrix (sigma)
    3. corresponding event-times (t)

    The coefficients (beta) and time periods (t) I can obtain using estat event, window (-4 4), however, I don't know how I can obtain the variance-covariance matrix (sigma). Could anyone please help me with the code to generate the variance-covariance matrix?

    Many thanks,

  • #2
    Hi Marcela,
    The variance covariance should also be accessible after estat event:
    Code:
    csdid  lemp lpop , ivar(countyreal) time(year) gvar(first_treat) method(dripw)
    estat event
    return list
    
                      r(V) :  7 x 7
                      r(b) :  1 x 7
                  r(table) :  9 x 7
    They will be inside r(V).

    Comment

    Working...
    X