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 on April 23, and its replacement, statalist.org is already up and running.


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

RE: st: AW: Artmenu fails to load in Stata 11


From   "Martin Weiss" <martin.weiss1@gmx.de>
To   <statalist@hsphsun2.harvard.edu>
Subject   RE: st: AW: Artmenu fails to load in Stata 11
Date   Wed, 19 May 2010 00:21:04 +0200

<>

Jonathan can attach a 

***********
ylab(#5)
***********

to the very end of the -stpower- call to get the original <
http://www.stata.com/stata10/i/ex3fix_big.gif >  "0.2" delta for the y-axis
labels...

HTH
Martin


-----Original Message-----
From: owner-statalist@hsphsun2.harvard.edu
[mailto:owner-statalist@hsphsun2.harvard.edu] On Behalf Of Yulia Marchenko,
StataCorp LP
Sent: Dienstag, 18. Mai 2010 23:59
To: statalist@hsphsun2.harvard.edu
Subject: Re: st: AW: Artmenu fails to load in Stata 11

Jonathan Kaplan <kaplan.joe@gmail.com> asks how to reproduce a power-curve
graph depicted on the Stata website:

> I am trying to reproduce the graph displayed in:
> 
> http://www.stata.com/stata10/poweranalysis.html
> 
> I'm able to reproduce the basic data using 
>
> . stpower logrank 0.7, n(100 250 500) hratio(0.1(0.01)0.9) saving(mypower)
>
> However I cannot figure the correct syntax to produce the graph.


Martin Weiss <martin.weiss1@gmx.de> showed a manual way of obtaining a graph
after -stpower-
(http://www.stata.com/statalist/archive/2010-05/msg01016.html).  Jonathan
can
also use the unofficial command -stpowplot- to obtain power curves for the
log-rank test more easily.  For example,

  . stpowplot logrank 0.7, yaxis(power) xaxis(hr) over(n)  ///
			   n(100 250 500) hratio(0.1(0.01)0.9)

will produce a graph similar to that displayed on the webpage.  Following
Martin's suggestions, Jonathan can customize the graph to obtain a closer
match:

/*** begin example ****/
local title Power curves for log-rank test
local subtitle (for survival curves of experimental vs. standard treatment)
local note1 Assumptions: alpha = 0.05 (two sided); equal number of subjects 
local note1 `note1' to be assigned to each group; 
local note2  70% of patients in the control group survive to the end of the
study
local xtitle Hypothesized effect size (hazard ratio of experimentals vs.
controls)
stpowplot logrank 0.7, yaxis(power) xaxis(hr) over(n)			///
                         n(100 250 500) hratio(0.1(0.01)0.9)		///
			 title(`title') subtitle(`subtitle')		///
			 note("`note1'" "`note2'") 			///
			 xtitle(`xtitle') yline(0.8, lstyle(refline))	///
			 legend(off) text(.65 .4 "N = 100") 		///
			 text(.65 .6 "N = 250") text(.65 .75 "N = 500")
/*** end example ****/

Type

  . findit stpowplot

to locate and install this command.


-- Yulia
ymarchenko@stata.com
*
*   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–2014 StataCorp LP   |   Terms of use   |   Privacy   |   Contact us   |   Site index