ONESAMPLEMEANS Statement 
The ONESAMPLEMEANS statement performs power and sample size analyses for tests, equivalence tests, and confidence interval precision involving one sample.
Table 70.10 summarizes categories of options available in the ONESAMPLEMEANS statement.
Task 
Options 

Define analysis 

Specify analysis information 

Specify effects 

Specify variability 

Specify sample size 

Specify power and related 

probabilities 

Control sample size rounding 

Control ordering in output 
Table 70.11 summarizes the valid result parameters for different analyses in the ONESAMPLEMEANS statement.
Analyses 
Solve For 
Syntax 

Power 

Sample size 

Alpha 

Mean 

Standard Deviation 

Power 

Sample size 

TEST=EQUIV 
Power 

Sample size 

CI=T 
Prob(width) 

Sample size 
specifies the level of significance of the statistical test or requests a solution for alpha with a missing value (ALPHA=.). The default is 0.05, corresponding to the usual 0.05 100% = 5% level of significance. If the CI= and SIDES=1 options are used, then the value must be less than 0.5. See the section Specifying Value Lists in Analysis Statements for information about specifying the numberlist.
specifies an analysis of precision of the confidence interval for the mean. Instead of power, the relevant probability for this analysis is the probability of achieving a desired precision. Specifically, it is the probability that the halfwidth of the confidence interval will be at most the value specified by the HALFWIDTH= option. If neither the CI= option nor the TEST= option is used, the default is TEST=T.
specifies the coefficient of variation, defined as the ratio of the standard deviation to the mean. You can use this option only with DIST=LOGNORMAL. See the section Specifying Value Lists in Analysis Statements for information about specifying the numberlist.
specifies the underlying distribution assumed for the test statistic. NORMAL corresponds the normal distribution, and LOGNORMAL corresponds to the lognormal distribution. The default value is NORMAL.
specifies the desired confidence interval halfwidth. The halfwidth is defined as the distance between the point estimate and a finite endpoint. This option can be used only with the CI=T analysis. See the section Specifying Value Lists in Analysis Statements for information about specifying the numberlist.
specifies the lower equivalence bound for the mean. This option can be used only with the TEST=EQUIV analysis. See the section Specifying Value Lists in Analysis Statements for information about specifying the numberlist.
specifies the mean, in the original scale, or requests a solution for the mean with a missing value (MEAN=.). The mean is arithmetic if DIST=NORMAL and geometric if DIST=LOGNORMAL. This option can be used only with the TEST=T and TEST=EQUIV analyses. See the section Specifying Value Lists in Analysis Statements for information about specifying the numberlist.
enables fractional input and output for sample sizes. See the section Sample Size Adjustment Options for information about the ramifications of the presence (and absence) of the NFRACTIONAL option.
specifies the sample size or requests a solution for the sample size with a missing value (NTOTAL=.). See the section Specifying Value Lists in Analysis Statements for information about specifying the numberlist.
specifies the null mean, in the original scale (whether DIST=NORMAL or DIST=LOGNORMAL). The default value is 0 when DIST=NORMAL and 1 when DIST=LOGNORMAL. This option can be used only with the TEST=T analysis. See the section Specifying Value Lists in Analysis Statements for information about specifying the numberlist.
controls how the input and default analysis parameters are ordered in the output. OUTPUTORDER=INTERNAL (the default) arranges the parameters in the output according to the following order of their corresponding options:
The OUTPUTORDER=SYNTAX option arranges the parameters in the output in the same order in which their corresponding options are specified in the ONESAMPLEMEANS statement. The OUTPUTORDER=REVERSE option arranges the parameters in the output in the reverse of the order in which their corresponding options are specified in the ONESAMPLEMEANS statement.
specifies the desired power of the test or requests a solution for the power with a missing value (POWER=.). The power is expressed as a probability, a number between 0 and 1, rather than as a percentage. This option can be used only with the TEST=T and TEST=EQUIV analyses. See the section Specifying Value Lists in Analysis Statements for information about specifying the numberlist.
specifies the type of probability for the PROBWIDTH= option. A value of CONDITIONAL (the default) indicates the conditional probability that the confidence interval halfwidth is at most the value specified by the HALFWIDTH= option, given that the true mean is captured by the confidence interval. A value of UNCONDITIONAL indicates the unconditional probability that the confidence interval halfwidth is at most the value specified by the HALFWIDTH= option. You can use the alias GIVENVALIDITY for CONDITIONAL. The PROBTYPE= option can be used only with the CI=T analysis. See the section Specifying Value Lists in Analysis Statements for information about specifying the keywordlist.
width probability conditional on interval containing the mean
unconditional width probability
specifies the desired probability of obtaining a confidence interval halfwidth less than or equal to the value specified by the HALFWIDTH= option. A missing value (PROBWIDTH=.) requests a solution for this probability. The type of probability is controlled with the PROBTYPE= option. Values are expressed as probabilities (for example, 0.9) rather than percentages. This option can be used only with the CI=T analysis. See the section Specifying Value Lists in Analysis Statements for information about specifying the numberlist.
specifies the number of sides (or tails) and the direction of the statistical test or confidence interval. See the section Specifying Value Lists in Analysis Statements for information about specifying the keywordlist. Valid keywords and their interpretation for the TEST= analyses are as follows:
onesided with alternative hypothesis in same direction as effect
twosided
upper onesided with alternative greater than null value
lower onesided with alternative less than null value
For confidence intervals, SIDES=U refers to an interval between the lower confidence limit and infinity, and SIDES=L refers to an interval between minus infinity and the upper confidence limit. For both of these cases and SIDES=1, the confidence interval computations are equivalent. The SIDES= option can be used only with the TEST=T and CI=T analyses. The default value is 2.
specifies the standard deviation, or requests a solution for the standard deviation with a missing value (STDDEV=.). You can use this option only with DIST=NORMAL. See the section Specifying Value Lists in Analysis Statements for information about specifying the numberlist.
specifies the statistical analysis. TEST=EQUIV specifies an equivalence test of the mean by using a two onesided tests (TOST) analysis (Schuirmann 1987). TEST or TEST=T (the default) specifies a test on the mean. If neither the TEST= option nor the CI= option is used, the default is TEST=T.
specifies the upper equivalence bound for the mean, in the original scale (whether DIST=NORMAL or DIST=LOGNORMAL). This option can be used only with the TEST=EQUIV analysis. See the section Specifying Value Lists in Analysis Statements for information about specifying the numberlist.
To define the analysis, choose one of the following parameterizations:
This section summarizes the syntax for the common analyses supported in the ONESAMPLEMEANS statement.
The following statements demonstrate a power computation for the onesample t test. Default values for the DIST=, SIDES=, NULLMEAN=, and ALPHA= options specify a twosided test for zero mean with a normal distribution and a significance level of 0.05.
proc power; onesamplemeans test=t mean = 7 stddev = 3 ntotal = 50 power = .; run;
The following statements demonstrate a sample size computation for the onesample t test for lognormal data. Default values for the SIDES=, NULLMEAN=, and ALPHA= options specify a twosided test for unit mean with a significance level of 0.05.
proc power; onesamplemeans test=t dist=lognormal mean = 7 cv = 0.8 ntotal = . power = 0.9; run;
The following statements demonstrate a power computation for the TOST equivalence test for a normal mean. Default values for the DIST= and ALPHA= options specify a normal distribution and a significance level of 0.05.
proc power; onesamplemeans test=equiv lower = 2 upper = 7 mean = 4 stddev = 3 ntotal = 100 power = .; run;
The following statements demonstrate a sample size computation for the TOST equivalence test for a lognormal mean. The default of ALPHA=0.05 specifies a significance level of 0.05.
proc power; onesamplemeans test=equiv dist=lognormal lower = 1 upper = 5 mean = 3 cv = 0.6 ntotal = . power = 0.85; run;
By default CI=T analyzes the conditional probability of obtaining the desired precision, given that the interval contains the true mean, as in the following statements. The defaults of SIDES=2 and ALPHA=0.05 specify a twosided interval with a confidence level of 0.95.
proc power; onesamplemeans ci = t halfwidth = 14 stddev = 8 ntotal = 50 probwidth = .; run;