Statalist


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

st: Re: Kaplan Meier plot: adding vertical line at median survival


From   "Martin Weiss" <[email protected]>
To   <[email protected]>
Subject   st: Re: Kaplan Meier plot: adding vertical line at median survival
Date   Sun, 2 Nov 2008 11:51:29 +0100

This works under 10.1, try it with your -version-:


sysuse cancer.dta, clear
stset studytime
sts graph, by(drug) addplot((pci -0.03 13 0.5 13 -0.03 25 0.5 25, lcolor(black)))



HTH
Martin
_______________________
----- Original Message ----- From: "Michael McCulloch" <[email protected]>
To: "Statalist" <[email protected]>
Sent: Sunday, November 02, 2008 4:04 AM
Subject: st: Kaplan Meier plot: adding vertical line at median survival


Greetings,
I'd like to plot a Kaplan Meier graph with a vertical line at the point of median survival, where the line begins at the x-axis and ends at the point where that vertical line intersects the survival curve.

For example:
sysuse cancer.dta
stset studytime
sts graph, by(drug)

In this example, for drug2 median survival is at 13 months, and for drug3, at 25 months, so I'd . Is this possible within the -sts graph- command? I'm using v9.2 and so don't have the manual graphical editing features of v10.

Thank you.

--

Best wishes,
Michael McCulloch



Pine Street Foundation
124 Pine St., San Anselmo, CA 94960-2674
Tel: (415) 407-1357
Fax: (415) 485-1065
[email protected]
www.pinestreetfoundation.org
*
*   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/



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