sdfordham / pysyncon

A python module for the synthetic control method
MIT License
41 stars 9 forks source link

pysyncon -> error in ATT estimate #54

Closed arasala closed 4 months ago

arasala commented 4 months ago

Hello. First of all, thank you very much for the development and sharing of the synthetic control method in Python. I was just checking how the ATT is estimated and there is an error in the order of the difference (base.py, line 125): the gaps (for the ATT) should be estimated as "ts_synthetic - Z1" (not "Z1 - ts_synthetic"). Taking the "base.py" file just as it is, returns the ATT with the wrong sign.

sdfordham commented 4 months ago

E.g. say the outcome for the treated unit after treatment is 10 (Z1 = 10) and the outcome for the (synthetic) control after the treatment time is 5 (ts_synthetic=5) then you say that att should be ts_synthetic - Z1 = 5 - 10 = -5?

arasala commented 4 months ago

My apologies, I just got confused with notation. You are correct. ATT is "Z1 - ts_synthetic".

sdfordham commented 4 months ago

No problem, all good.