ci.mean: Power calculation for precision analysis (confidence interval) for one mean
Description
Calculates the "power" of a confidence interval for one mean, that is, the probability
of achieving a 100(1 - alpha) percent confidence interval with halfwidth not greater
than a specified value. Can solve for power, N or alpha.
Usage
ci.mean(
N = NULL,
halfwidth = NULL,
sd = 1,
alpha = 0.05,
power = NULL,
cond = FALSE,
v = FALSE
)
Value
A list of the arguments (including the computed one).
Arguments
N
The sample size.
halfwidth
The desired halfwidth.
sd
The estimated standard deviation; defaults to 1.
alpha
The significance level (type 1 error rate); defaults to 0.05.
power
The specified level of power.
cond
Specify whether to use unconditional or conditional probability. Defaults to FALSE (unconditional).
v
Either TRUE for verbose output or FALSE (default) to output computed argument only.
Details
The unconditional probability is the probability of obtaining the desired precision
(i.e., that the observed halfwidth does not exceed the desired halfwidth)
regardless of whether or not the confidence interval includes the true parameter value.
The conditional probability is the probability of both obtaining the desired precision and having
the interval include the true parameter value.