
Simulate Power to Select Best Group (Normal Outcomes)
Source:R/sim_power_best_normal.R
sim_power_best_normal.Rd
Estimates the empirical power to identify the most promising group as the best, when outcomes are normally distributed and independent.
Arguments
- noutcomes
Integer. Number of outcomes to evaluate.
- sd
Numeric vector. Standard deviations for each outcome. Can be a single value.
- dif
Numeric vector. Difference in means between the best and the other groups.
- ngroups
Number of groups to compare.
- npergroup
Number of subjects per group. Can be scalar or vector of length
ngroups
.- nsim
Integer. Number of simulations to perform.
- conf.level
Numeric. Confidence level for the empirical power estimate
Value
An S3 object of class empirical_power_result
, which contains
the estimated empirical power and its confidence interval. The object can
be printed, formatted, or further processed using associated S3 methods.
See also empirical_power_result
.
Details
The best group (group 1)
is assumed to have mean 0, and the rest of the groups have mean -dif
.
Multiple outcomes can be evaluated simultaneously. The power is estimated as the proportion of simulations where the most promising group is the best in all outcomes.
The number of subjects per group can be the same or specified per group. In either case, the first group is assumed to be the most promising.