Bioequivalence (2x2 crossover, exact TOST noncentral t, 80-125%)
Source:R/calc-margins-be.R
calculate_bioequivalence.RdEvaluates exact joint power of the two one-sided tests (TOST) by integrating the conditional normal acceptance probability over the independent chi-square variance estimate (Phillips 1990). Uses balanced even totals and reports an error if the target power cannot be reached within 10000 participants. Matches sampleN.TOST in the PowerTOST package exactly.
Usage
calculate_bioequivalence(
cv,
alpha,
power,
theta0 = 1,
margin_low = 0.8,
margin_high = 1.25
)