ONEWAYANOVA <options>;
The ONEWAYANOVA statement performs power and sample size analyses for onedegreeoffreedom contrasts and the overall F test in oneway analysis of variance.
Table 89.14 summarizes the options available in the ONEWAYANOVA statement.
Table 89.14: ONEWAYANOVA Statement Options
Option 
Description 

Define analysis 

Specifies the statistical analysis 

Specify analysis information 

Specifies the significance level 

Specifies coefficients for singledegreeoffreedom hypothesis tests 

Specifies the null value of the contrast 

Specifies the number of sides and the direction of the statistical test 

Specify effect 

Specifies the group means 

Specify variability 

Specifies the error standard deviation 

Specify sample size and allocation 

Specifies the group sample sizes 

Specifies the sample size allocation weights for the groups 

Enables fractional input and output for sample sizes 

Specifies the common sample size per group 

Specifies the sample size 

Specify power 

Specifies the desired power of the test 

Control ordering in output 

Controls the output order of parameters 
Table 89.15 summarizes the valid result parameters for different analyses in the ONEWAYANOVA statement.
Table 89.15: Summary of Result Parameters in the ONEWAYANOVA Statement
Analyses 
Solve For 
Syntax 

TEST= CONTRAST 
Power 
POWER= . 
Sample size 
NTOTAL= . 

NPERGROUP= =. 

TEST= OVERALL 
Power 
POWER= . 
Sample size 
NTOTAL= . 

NPERGROUP= =. 
To specify the sample size and allocation, choose one of the following parameterizations:
sample size per group in a balanced design (by using the NPERGROUP= = option)
total sample size and allocation weights (by using the NTOTAL= and GROUPWEIGHTS= options)
individual group sample sizes (by using the GROUPNS= option)
This section summarizes the syntax for the common analyses that are supported in the ONEWAYANOVA statement.
You can use the NPERGROUP= = option in a balanced design, as in the following statements. Default values for the SIDES= , NULLCONTRAST= , and ALPHA= options specify a twosided test for a contrast value of 0 with a significance level of 0.05.
proc power; onewayanova test=contrast contrast = (1 0 1) groupmeans = 3  7  8 stddev = 4 npergroup = 50 power = .; run;
You can also specify an unbalanced design with the NTOTAL= and GROUPWEIGHTS= options:
proc power; onewayanova test=contrast contrast = (1 0 1) groupmeans = 3  7  8 stddev = 4 groupweights = (1 2 2) ntotal = . power = 0.9; run;
Another way to specify the sample sizes is with the GROUPNS= option:
proc power; onewayanova test=contrast contrast = (1 0 1) groupmeans = 3  7  8 stddev = 4 groupns = (20 40 40) power = .; run;
The following statements demonstrate a power computation for the overall F test in a oneway ANOVA. The default of ALPHA= 0.05 specifies a significance level of 0.05.
proc power; onewayanova test=overall groupmeans = 3  7  8 stddev = 4 npergroup = 50 power = .; run;