![]() |
From | "Michael I. Lichter" <mlichter@buffalo.edu> |
To | statalist@hsphsun2.harvard.edu |
Subject | Re: st: paired t-test on matched sample after propensity score matching |
Date | Fri, 14 Aug 2009 12:22:03 -0400 |
Thomas,More specifically, you need to merge each matched pair of cases into a single record using -reshape wide-. Each pair must have a common id plus a flag specifying which is treated and which is untreated. The command would look something like -reshape wide outcome, i(id) j(treatflag)-. You will probably need to experiment to get just what you want.
Michael Neil Shephard wrote:
On Fri, Aug 14, 2009 at 4:59 PM, Weichle, Thomas<Thomas.Weichle@va.gov> wrote:Dear Statalisters, I'm trying to do a paired t-test on a matched sample after performing propensity score matching to assess differences in measured characteristics between treated and untreated individuals. I've used psmatch2 to perform the matching. I'm familiar with the syntax to do a paired t-test when there are 2 variables and we want to test whether they differ (ttest varname1 == varname2). However, the way my data is set up after performing the matching doesn't have 2 separate variables. For example, there is 1 column for each measured characteristic, an indicator for treatment status, and another variable indicating which control the treated was matched to. Does anyone have any experience trying to perform this matched individuals paired t-test? Maybe I don't have my data set up correctly.You're correct, you need to -reshape- your data first. See -man reshape- for more information. Neil
-- Michael I. Lichter, Ph.D. <mlichter@buffalo.edu> Research Assistant Professor & NRSA Fellow UB Department of Family Medicine / Primary Care Research Institute UB Clinical Center, 462 Grider Street, Buffalo, NY 14215 Office: CC 126 / Phone: 716-898-4751 / FAX: 716-898-3536 * * For searches and help try: * http://www.stata.com/help.cgi?search * http://www.stata.com/support/statalist/faq * http://www.ats.ucla.edu/stat/stata/
© Copyright 1996–2025 StataCorp LLC | Terms of use | Privacy | Contact us | What's new | Site index |