n_glm.Rd
Estimation of required sample size as given by Cundill & Alexander (2015).
n_glm(
mean0,
mean1,
dispersion0,
dispersion1,
alpha,
power,
link_fun = function(mu) NULL,
variance_fun = function(mu, dispersion) NULL,
dmu_deta_fun = function(mu) NULL,
q
)
Mean in control group
Mean in treatment group
Dispersion parameter in control group
Dispersion parameter in treatment group.
Type I error rate
1 - Type II error rate
function object, the link function to create the response \(\eta\).
function object, function for computing the variance based on a mean and a dispersion parameter
function object, derivative of the original mean with respect to the link: \(d\mu / d\eta\).
Number between 0 and 1, the proportion of observations allocated to the control group
Total sample size (numeric)
Cundill, B., & Alexander, N. D. E. (2015). Sample size calculations for skewed distributions. BMC Medical Research Methodology, 15(1), 1–9. https://doi.org/10.1186/s12874-015-0023-0