View source: R/calibrate_cutoff_bin_2arm.R
| calibrate_cutoff_bin_2arm | R Documentation |
The calibrate_cutoff_bin_2arm function is designed to calibrate the
posterior probability cutoff for a two-arm comparative trial with a binary
endpoint under one borrowing strategy: self-adapting mixture prior (SAM),
robust MAP prior with fixed weight (rMAP), or non-informative prior (NP).
calibrate_cutoff_bin_2arm(
if.prior,
nf.prior,
prior.t = nf.prior,
target = 0.05,
n.t,
n,
theta.t = NULL,
theta = NULL,
delta,
method = c("SAM", "rMAP", "NP"),
alternative = c("greater", "less"),
margin = 0,
weight_rMAP = 0.5,
method.w = "LRT",
prior.odds = 1,
interval = c(0.5, 0.999),
rel.tol = 1e-05,
oc_rel.tol = 1e-08
)
if.prior |
Informative prior constructed based on historical data for the control arm, represented (approximately) as a beta mixture prior. |
nf.prior |
Non-informative prior used for the mixture. |
prior.t |
Prior used for the treatment arm. If missing, the default
value is set to be |
target |
Target rejection probability under the calibration scenario, typically the desired type I error rate when the calibration scenario corresponds to the null hypothesis. |
n.t |
Sample size for the treatment arm. |
n |
Sample size for the control arm. |
theta.t |
The response rate for the treatment arm under the calibration scenario. |
theta |
The response rate for the control arm under the calibration scenario. |
delta |
Clinically significant difference used for the SAM prior.
This argument is only used when |
method |
Borrowing strategy for the control arm. Must be one of
|
alternative |
Direction of the posterior decision. Must be one of
|
margin |
Clinical margin. Must be non-negative. Default is |
weight_rMAP |
Weight assigned to the informative prior component
( |
method.w |
Methods used to determine the mixture weight for SAM priors.
The default method is "LRT" (Likelihood Ratio Test), the alternative option
is "PPR" (Posterior Probability Ratio). See |
prior.odds |
The prior probability of |
interval |
Search interval for the posterior probability cutoff. The default is from 0.5 to 0.999. |
rel.tol |
Tolerance passed to |
oc_rel.tol |
Relative tolerance passed to scenario-level calculations. |
The calibrated cutoff is chosen so that the repeated-sampling rejection probability under a specified scenario equals the target value.
The function solves for the posterior probability cutoff such that the
scenario-level rejection probability returned by
eval_scenario_bin_2arm matches target. Under null
scenarios, this corresponds to calibration of the type I error.
A list with the following elements:
Calibrated posterior probability cutoff.
Value of the root-finding objective at the solution.
Target rejection probability.
Borrowing method used.
Direction of the posterior decision.
Clinical margin used for inference.
True control-arm response rate under the calibration scenario.
True treatment-arm response rate under the calibration scenario.
Search interval used for calibration.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.