Produces a reporting-ready summary table of bioequivalence (BE) analysis results from a PKanalix project, including geometric mean ratios (GMR), confidence intervals, and BE conclusions for every test vs. reference comparison. Supports per-parameter rounding, (custom) aliases/units, and optional BE acceptance limits and conclusion columns.
Usage
tableBEResults(projectFile = NULL,
selectParameters = NULL,
roundDigits = 3,
roundMethod = c("monolixSuiteRounding", "significantFigures", "significantFiguresPreserved", "none"),
roundByParameter = NULL,
units = TRUE,
aliases = TRUE,
customUnits = NULL,
customAliases = NULL,
BELimits = FALSE,
BEConclusion = TRUE,
prettyLabels = TRUE,
mock = FALSE)
Arguments
-
projectFile(character) Path to a PKanalix project file (.pkx). IfNULL(default), uses the currently loaded project. -
selectParameters(character) Parameter names to include. IfNULL(default), all BE parameters are included. -
roundDigits(integer) Number of decimal places for rounding (default3). -
roundMethod(character) How numeric values are rounded:-
"monolixSuiteRounding"(default) - Mirrors MonolixSuite display. The integer part is kept exactly as-is, and only the fractional part is rounded toroundDigitssignificant figures (so small values < 1 get more decimal places). -
"significantFigures"- Standard significant-figures rounding toroundDigitstotal significant digits, zeroing non-significant digits before the decimal for large numbers. -
"significantFiguresPreserved"- Like"significantFigures", but never zeroes digits before the decimal: once the integer part already hasroundDigitsdigits, the value is rounded to the nearest whole number. -
"none"- No rounding.
-
-
roundByParameterOptional per-parameter rounding overrides on top of the global settings, either a named numeric vector of digits (c(Cmax = 2, AUClast = 4)) or a 3-column data frame (parameter,digits,method). Unlisted parameters keep global settings (defaultNULL). -
units(logical) IfTRUE(default), appends units to parameter names (e.g."ln(AUClast) (h*ng/mL)"). Units are retrieved from project settings. -
aliases(logical) IfTRUE(default), uses parameter aliases instead of raw parameter names (e.g."AUC[[sub:0-tlast]]"instead of"AUClast"). -
customUnits(character / data.frame) Named vector or 2-column data frame mapping parameters → custom unit labels, e.g.c(Cmax = "ng/mL", AUClast = "h*ng/mL"). Overrides units from the PKanalix project. -
customAliases(character / data.frame) Named vector or 2-column data frame mapping parameters → custom alias labels, e.g.c(Cmax = "C[[sub:max]]", AUClast = "AUC[[sub:0-tlast]]"). Overrides project aliases. Supports[[sub:…]],[[sup:…]],~italic~. -
BELimits(logical) IfTRUE, includes a column showing the BE acceptance criteria interval (e.g."(80;125)"), retrieved from the project's BE settings. DefaultFALSE. -
BEConclusion(logical) IfTRUE(default), includes a conclusion column indicating"Bioequivalent"or"Not bioequivalent"based on the analysis results. -
prettyLabels(logical) IfTRUE(default), converts column names to human-readable labels (e.g."Ratio (%)","Confidence Interval"). -
mock(logical) IfTRUE, masks values for documentation/examples: the ratio, confidence-interval, and BE-limits columns become placeholders (e.g."xx.xx","(xx.xx;xx.xx)");Comparison, the parameter name, andConclusionare relabeled generically per unique value ("Comparison 1","Parameter 1","Conclusion 1"…), with the same parameter keeping the same label across all its comparison rows. DefaultFALSE.
Returns: A data frame of BE results with columns for comparison, parameter, GMR (ratio), and confidence interval, plus optional BE limits and conclusion columns. Parameters analyzed on the log scale are indicated with an ln() prefix.
Examples