Hi,
This is my first post to Statalist so please bare with me.
I am currently working with an observational dataset (approx 5000 observations) wanting to look for treatment effect of the treatment tpa_alle on the outcome mrs3mnd_xlnt (binary categorical). I have used the psmatch2 command for propensity score matching based on treatment status and 10 other variables. I have done a 1:1 matching, but also wish to do a 1:2 matching to see if this gives me similar results.
This is where my problem arises.
For the matching with 2 nearest neighbors I used the following code:
When I try to check how many cases in each group after matching it looks to me like it didn't give me a 1:2 match.
I tried
which shows 804 cases in the untreated group and 526 treated.
Is this because som controls/untreated cases are used more than once? Other explanations? Other ways of displaying the number of cases in the matched groups?
I also used the following code to identify the matched pairs and tried to use this to look at the no of cases in each group:
Followed by:
This however retured 389 treated and 687 untreated and thus left me even more confused as the no of cases in the two group differ depending on apporach when I thought these two options were similar. Any one have any insight on which approach is correct -if any?
Thankful for your suggestions!
Cheers
Mary-Helen
This is my first post to Statalist so please bare with me.
I am currently working with an observational dataset (approx 5000 observations) wanting to look for treatment effect of the treatment tpa_alle on the outcome mrs3mnd_xlnt (binary categorical). I have used the psmatch2 command for propensity score matching based on treatment status and 10 other variables. I have done a 1:1 matching, but also wish to do a 1:2 matching to see if this gives me similar results.
This is where my problem arises.
For the matching with 2 nearest neighbors I used the following code:
Code:
psmatch2 tpa_alle c.patientage gender c.nihssinnkomst i.mrspre logreg_af logreg_prebtrx logreg_priormi tidltia livesalone i.hospital_volume_3_groups if wus_kos_uos==1 & tidlhjerneslag==0, n(2) caliper(0.2) odds logit
I tried
Code:
tab tpa_alle if _weight!=.
Is this because som controls/untreated cases are used more than once? Other explanations? Other ways of displaying the number of cases in the matched groups?
I also used the following code to identify the matched pairs and tried to use this to look at the no of cases in each group:
Code:
gen pair1 = _id if _treated==0 replace pair1 = _n1 if _treated==1 gen pair2 = _id if _treated==0 replace pair2 = _n2 if _treated==1 bysort pair1: egen paircount1 = count(pair1) bysort pair2: egen paircount2 = count(pair2) egen byte paircount = anycount(paircount1 paircount2), values(2)
Code:
tab tpa_alle if paircount!=0
Thankful for your suggestions!
Cheers
Mary-Helen
Comment