Documentation Example 1 for PROC POWER
/****************************************************************/
/* S A S S A M P L E L I B R A R Y */
/* */
/* NAME: pwrex01 */
/* TITLE: Documentation Example 1 for PROC POWER */
/* (One-Way ANOVA) */
/* PRODUCT: STAT */
/* SYSTEM: ALL */
/* KEYS: power */
/* sample size */
/* power analysis */
/* analysis of variance */
/* graphs */
/* PROCS: POWER */
/* DATA: */
/* */
/* SUPPORT: John Castelloe */
/* REF: */
/* MISC: Graphs produced by ODS Graphics in PROC POWER */
/* require a style that distinguishes curves based */
/* on a combination of color, line style, and symbol */
/* marker. Styles that are well-suited for use in */
/* PROC POWER include: STATISTICAL, ANALYSIS, DEFAULT, */
/* LISTING, and HTMLBLUECML. */
/****************************************************************/
proc power;
onewayanova
groupmeans = 35.6 | 33.7 | 30.2 | 29 28 | 25.9
stddev = 3.75
groupweights = (2 1 1 1 1)
alpha = 0.025
ntotal = .
power = 0.9
contrast = (4 -1 -1 -1 -1) (0 1 1 -1 -1)
(0 1 -1 0 0) (0 0 0 1 -1);
run;
*
ods listing style=htmlbluecml;
ods graphics on;
proc power plotonly;
onewayanova
groupmeans = 35.6 | 33.7 | 30.2 | 29 28 | 25.9
stddev = 3.75
groupweights = (2 1 1 1 1)
alpha = 0.025
ntotal = .
power = 0.9
contrast = (4 -1 -1 -1 -1) (0 1 1 -1 -1)
(0 1 -1 0 0) (0 0 0 1 -1);
plot x=power min=.5 max=.95;
run;
proc power plotonly;
onewayanova
groupmeans = 35.6 | 33.7 | 30.2 | 29 28 | 25.9
stddev = 3.75
groupweights = (2 1 1 1 1)
alpha = 0.025
ntotal = 24
power = .
contrast = (4 -1 -1 -1 -1) (0 1 1 -1 -1)
(0 1 -1 0 0) (0 0 0 1 -1);
plot x=n min=24 max=480;
run;
ods graphics off;