So, you need the variable which identifies each pair. I haven't used -psmatch2- in a long time and I don't remember how you get that variable. BUt, let's assume you have it and it's called pairid. You also presumably have a subject_id for each person (or firm, or whatever they are). Then you have to account for the pairing as follows:
Code:
mixed y t x1 x2 || pair_id: || subject_id
BUT, there is another problem. You said you want to do a difference in differences analysis. That regression equation doesn't do that. So you also need another variable that indicates pre- and post- onset of treatment status, call it pre_post. Then what you want is:
Code:
mixed y i.t##i.pre_post x1 x2 || pair_id: || subject_id:
The DID estimator of the treatment effect will be the coefficient of 1.t#.pre_post. The best way to understand the results, though, is to look at predicted outcomes in each group both before and after the onset of treatment. -margins t#pre_post- will give you that.
|