Hi all,
I am designing a nested case-control study using cohort data and would like some help with matching using the stset + sttocc command.
My failure event is the development of a disease (brain cancer).
I have worked out how to match for "sex" and "birth year" using stset and sttocc.
gen xitdate=mdy(xitmo, xitdy, xityr)
stset xitdate, failure(cns==1) id(id) scale(365.25)
set seed 9123456
sttocc, match (sex byr) n(5) nodots
list _set id _case _time sex byr, sepby(_set)
However, I would like my controls to be matched not only for sex and birth year but additionally for date of diagnosis (i.e. each control has the same date as their matched case over the same date of diagnosis).
Is there a way to do this?
Many thanks,
Ye Jin Bang.
Related Posts with stset+sttocc matching - nested case-control study
How can these two datasets reshape between each other?Hi, I have two datasets linked below. Can anyone help me to reshape them between each other using S…
Interpretation Competing Risk (Stcrreg) – Comparability of CovariatesDear Stata Users, I have a question regarding the interpretation and comparability of the hazard ra…
How to append a sub-set of observations.Hi everyone, So, I have a very large yearly database on students of different educational levels (3…
How do I store coefficients from GARCH model in a postfile Code: capture postutil clear postfile table1 arch using "vov.garch.dta", replace arch vov, arch(1…
Admetan | Forest plot formattingHello, I have a series of forest plots, which I need to edit further. An extract of the code for o…
Subscribe to:
Post Comments (Atom)
0 Response to stset+sttocc matching - nested case-control study
Post a Comment