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

From |
"Carlo Lazzaro" <carlo.lazzaro@tiscalinet.it> |

To |
<statalist@hsphsun2.harvard.edu> |

Subject |
R: st: R: Kaplan meier graphs |

Date |
Thu, 5 Feb 2009 14:06:56 +0100 |

Dear Sarah, taking a look at Stata manual release 9 (Volume Survival analysis and epidemiological tables: 269-272) it seems that you can adjust your KM estimates for more variables at the same time. Please, see example below (Stata 9.2/SE): ---------------------begin example-------------------------------------- sysuse cancer.dta (Patient Survival in Drug Trial) save "C:\Documents and Settings\carlo\Desktop\sarah.dta" stset studytime, failure(died) g alfa=1 if died ==0 replace alfa =0 if alfa ==. sts graph, by(drug) adjustfor( alfa age) ----------------------end example---------------------------------------- HTH and Kind Regards, Carlo -----Messaggio originale----- Da: owner-statalist@hsphsun2.harvard.edu [mailto:owner-statalist@hsphsun2.harvard.edu] Per conto di sarah keys Inviato: giovedì 5 febbraio 2009 13.26 A: statalist@hsphsun2.harvard.edu Oggetto: Re: st: R: Kaplan meier graphs Thanks Carlo - that worked! I don't suppose you (or anyone else) know about adjusting KM? I am not even sure if it make sense to adjust survival functions? I can adjust by one factor i.e: age shown below: sts,by(group) fail adjustfor(age) ylabel(0 0.1 0.25) tmax(2) but what about for multiple factors - can't get the coding right Really appreciate this help as I am a newy! Many thanks Sarah On Thu, Feb 5, 2009 at 12:26 PM, Carlo Lazzaro <carlo.lazzaro@tiscalinet.it> wrote: > Dear Sarah, > as far as > <How do I cut off KM at, say, 4 years follow-up ?> > Try (Stata 9/2 SE) > - sts graph, tmax(4)- > > HTH and Kind Regards, > Carlo > > -----Messaggio originale----- > Da: owner-statalist@hsphsun2.harvard.edu > [mailto:owner-statalist@hsphsun2.harvard.edu] Per conto di sarah keys > Inviato: giovedì 5 febbraio 2009 10.51 > A: statalist@hsphsun2.harvard.edu > Oggetto: st: Kaplan meier graphs > > Kaplan meier graphs > > I am using a multiple record data set. and have Stset as below: > > stset date_visit if chc!="", enter(all) fail(chcstop) id(client_id) > origin(startn)scale(365.25) > > *** and had the final cox model: > xi: stcox i.group age bffa i.w50s > > I produced KM graph with the following commands: > > sts,by(group) fail ylabel(0 0.05 0.1) risktable > graph export chc.emf, replace > > > My questions are: > Can I adjust the KM in the same way as the COX model (adjust by age > bffa i.w50s)to compare group 1 and group 2? > How do I cut off KM at, say, 4 years follow-up ? > Thanks for help > Sarah > * > * 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/ > > > > * > * 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/ > * * 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/ * * 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/

**References**:**Re: st: R: Kaplan meier graphs***From:*sarah keys <stkeyz@gmail.com>

- Prev by Date:
**Re: st: R: Kaplan meier graphs** - Next by Date:
**Re: st: RE: large numbers in comb(n,k) function: no success** - Previous by thread:
**Re: st: R: Kaplan meier graphs** - Next by thread:
**st: cumulative moving sum when there are repeated date values** - Index(es):

© Copyright 1996–2015 StataCorp LP | Terms of use | Privacy | Contact us | What's new | Site index |