size.test.mean1: Sample size for a test of a single mean

View source: R/statpsych1.R

size.test.mean1R Documentation

Sample size for a test of a single mean

Description

Computes the sample size required to test a single population mean with desired power in a 1-group design. Set the variance planning value to the largest value within a plausible range for a conservatively large sample size.

Usage

size.test.mean1(alpha, pow, var, es)

Arguments

alpha

alpha level for hypothesis test

pow

desired power

var

planning value of response variable variance

es

planning value of mean minus null hypothesis value

Value

Returns the required sample size

Examples

size.test.mean1(.05, .9, 80.5, 7)

# Should return:
#      Sample size
# [1,]          20
 


statpsych documentation built on July 9, 2023, 6:50 p.m.