Bookmark and Share

Notice: On March 31, it was announced that Statalist is moving from an email list to a forum. The old list will shut down at the end of May, and its replacement, statalist.org is already up and running.


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: st: data structure for case control


From   Kieran McCaul <kieran.mccaul@uwa.edu.au>
To   "statalist@hsphsun2.harvard.edu" <statalist@hsphsun2.harvard.edu>
Subject   RE: st: data structure for case control
Date   Tue, 11 Dec 2012 09:59:58 +0800

...

If you already have the data for the cases and the controls, why do you want the match them on age?

Matching is a feature of the design of a study and is carried out as the data are collected.  In other words, matching is done for efficiency. If you already have the data, there is nothing to be gained by matching.





-----Original Message-----
From: owner-statalist@hsphsun2.harvard.edu [mailto:owner-statalist@hsphsun2.harvard.edu] On Behalf Of Sacamano, Paul L.
Sent: Tuesday, 11 December 2012 6:33 AM
To: statalist@hsphsun2.harvard.edu
Subject: Re: st: data structure for case control

That is very helpful. Would it be the same for a study matching cases with controls on age frequency distribution? I currently have two files, one of cases and the other controls. I think I need to create an AGECLASS variable in both and then merge them together matching on AGECLASS. I expect there is a Stata command to then pair them together 1 to 2 within each class.
Thanks again.
Paul

On Dec 10, 2012, at 4:38 PM, Adam Olszewski <adam.olszewski@gmail.com> wrote:

> Hi Paul,
> The easy way would be to have one row per observation/patient and each 
> variable as one column. There would be one column AGE and one column 
> CASECONTROL, which you can assign 1 for cases and 0 for controls. This 
> way you can do "standard epidemology table" commands such as -cc- or 
> survival analysis with single-line commands using your "casecontrol"
> variable as an indicator of the arm.
> Good luck,
> Adam Olszewski
> 
> 
> On Mon, Dec 10, 2012 at 2:59 PM, Sacamano, Paul L. <psacaman@jhsph.edu> wrote:
>> Hi,
>> 
>> I am very new to Stata, very much a beginner.
>> 
>> I have a case-control study and am not sure how to setup the structure of the data file.
>> 
>> Using the variable age as an example, would I have:
>> 1) a variable for CASE_AGE and CONTROL_AGE, or
>> 2) have just one AGE variable, and include a CASE variable and a CONTROL variable?
>> 
>> Really appreciate any help you might have.
>> 
>> 
>> *
>> *   For searches and help try:
>> *   http://www.stata.com/help.cgi?search
>> *   http://www.stata.com/support/faqs/resources/statalist-faq/
>> *   http://www.ats.ucla.edu/stat/stata/
> *
> *   For searches and help try:
> *   http://www.stata.com/help.cgi?search
> *   http://www.stata.com/support/faqs/resources/statalist-faq/
> *   http://www.ats.ucla.edu/stat/stata/


*
*   For searches and help try:
*   http://www.stata.com/help.cgi?search
*   http://www.stata.com/support/faqs/resources/statalist-faq/
*   http://www.ats.ucla.edu/stat/stata/

*
*   For searches and help try:
*   http://www.stata.com/help.cgi?search
*   http://www.stata.com/support/faqs/resources/statalist-faq/
*   http://www.ats.ucla.edu/stat/stata/


© Copyright 1996–2014 StataCorp LP   |   Terms of use   |   Privacy   |   Contact us   |   Site index