ASA Connect

 View Only
  • 1.  STATA code for matching

    Posted 09-20-2016 13:00

    Hello all,

    I have 1510 observations where there are 195 cases and 1315 controls. I want to create a randomized data set where cases and controls are matched on age and Gender. I want to keep all the IAT as they are less in number. I would like to match cases and controls in 1:4 ratio. I have variables such as Id, Group (where 1=Case and 2=control), Sex(1=F and 2=M), age, and some other outcome variables which we want to compare between case and Control group after the data set is randomized. I have STATA 14 version. What would be the best way to do this? Any insight is highly appreciated.

    Thanks,

    PA

    ------------------------------
    Priyanka Acharya
    Biostatistician
    Methodist Health System
    ------------------------------


  • 2.  RE: STATA code for matching

    Posted 09-21-2016 07:55
    First, I suggest you post this to the Statalist server (statalist.org)
    as you are much more likely to get responses there

    second, there are no official Stata commands for this but there are a
    number, I understand, of user-written commands for this; e.g., I have
    used "vmatch" which is available at the SSC site (type "help ssc" for
    more information)

    Best,
    Rich




  • 3.  RE: STATA code for matching

    Posted 09-21-2016 13:01

    i agree that the statlist is the place to go for code, but before that, decide what your age windows are.  do you want to match on 'exact' (years completed, or rounded age) or some wider criterion (e.g. within the same 5-year age group, difference in age <= 5 years (these are not the same), difference in age < 10% of median)?

    ------------------------------
    Ellen Hertzmark



  • 4.  RE: STATA code for matching

    Posted 09-21-2016 20:59

    Would it matter to you if sometimes a case had only 3 controls that matched? Or sometimes only 2 controls that matched?

    ------------------------------
    Eric Siegel, MS
    Research Associate
    Department of Biostatistics
    Univ. Arkansas Medical Sciences



  • 5.  RE: STATA code for matching

    Posted 09-21-2016 21:20

    If you have already collected the 1510 observations, you've already spent the money, so why not try to keep all of them? For example, if you have two cases and 12 controls who are 55-year-old females, they are matched for sex and age. Why select 8 controls for the two cases and throw away 4 controls? Why not keep them all?

    ------------------------------
    Eric Siegel, MS
    Research Associate
    Department of Biostatistics
    Univ. Arkansas Medical Sciences



  • 6.  RE: STATA code for matching

    Posted 09-22-2016 04:31

    Thank you all for the responses. I have posted in the STATAlist and have found what I was looking for. Thank you.

    ------------------------------
    Priyanka Acharya
    Biostatistician
    Methodist Health System