Simulated power under independent-cell assumptions
Source:R/statistics-power.R
cr_power_analysis.RdA Monte-Carlo approximation of the power of a two-sample comparison
of replicate means formed from independent, unit-variance normal cells.
There is no between-unit random effect or intraclass correlation. The
result is an idealized scenario, not a validated estimate of power for a
clustered biological assay or a formal upper bound on laboratory power.
For a follow-up design use cr_power() with an effect on the independent
experimental-unit scale, or a separately specified correlated-data model.
Usage
cr_power_analysis(
effect_size,
n_replicates,
n_cells_per_rep,
alpha = 0.05,
test = "t_test",
n_sim = 500,
seed = NULL
)Arguments
- effect_size
Cohen's d at the cell level.
- n_replicates
Number of replicate units per group.
- n_cells_per_rep
Cells per replicate unit.
- alpha
Type I error rate.
- test
Only
"t_test"is implemented.- n_sim
Number of simulations (default 500).
- seed
Optional integer seed. The caller's random number stream is restored on exit.
See also
Other power:
cr_conservative_effect(),
cr_power(),
cr_power_grid()