psborrow.bin {psBayesborrow}R Documentation

Simulation study of hybrid control design with Bayesian dynamic borrowing incorporating propensity score matched external control: binary outcome

Description

Simulation study is conducted to assess operating characteristics of hybrid control design with Bayesian dynamic borrowing, where the concurrent control is augmented by external control. The external controls are selected from external control pool using a propensity score matching. Commensurate power prior is used for Bayesian dynamic borrowing. The binary outcome is applicable.

Usage

psborrow.bin(
  n.CT, n.CC, n.ECp, n.EC,
  out.prob.CT, out.prob.CC, driftOR,
  cov.C, cov.cor.C, cov.EC, cov.cor.EC, cov.effect,
  psmatch.cov,
  method.psest="glm", method.pslink="logit",
  method.whomatch, method.matching, method.psorder, n.boot=100,
  analysis.cov, method.borrow,
  chains=2, iter=4000, warmup=floor(iter/2), thin=1,
  alternative="greater", sig.level=0.025, nsim)

Arguments

n.CT

Number of patients in treatment group in the current trial.

n.CC

Number of patients in concurrent control group in the current trial.

n.ECp

Number of patients in external control pool.

n.EC

Number of patients in external control.

out.prob.CT

True rate of outcome in treatment group in the current trial.

out.prob.CC

True rate of outcome in concurrent control group in the current trial.

driftOR

Odds ratio between concurrent and external control for which the bias should be plotted (odds in external control divided by odds in concurrent control).

cov.C

List of covariate distributions for treatment and concurrent control group in the current trial. Continuous and binary covariate are applicable. The continuous covariate is assumed to follow a normal distribution; for example, specified as list(dist="norm", mean=0, sd=1, lab="cov1"). The binary covariate is assumed to follow a binomial distribution; for example, specified as list(dist="binom", prob=0.4, lab="cov2"). lab is the column name of the covariate in the data frame generated.

cov.cor.C

Matrix of correlation coefficients for each pair of covariate for treatment and concurrent control group in the current trial, specified as Gaussian copula parameter.

cov.EC

List of covariate distributions for external control. The continuous covariate is assumed to follow a normal distribution; for example, specified as list(dist="norm", mean=0, sd=1, lab="cov1"). The binary covariate is assumed to follow a binomial distribution; for example, specified as list(dist="binom", prob=0.4, lab="cov2"). lab is the column name of the covariate in the data frame generated, which must be consistent with those used for cov.C.

cov.cor.EC

Matrix of correlation coefficients for each pair of covariate for external control, specified as Gaussian copula parameter.

cov.effect

Vector of covariate effects on the outcome, specified as odds ratio per one unit increase in continuous covariates or as odds ratio between categories for binary covariates.

psmatch.cov

Vector of names of covariates which are used for the propensity score matching. The names of covariates must be included in lab values specified in cov.C.

method.psest

Method of estimating the propensity score. Allowable options include, for example, "glm" for generalized linear model (e.g., logistic regression); "gam" for generalized additive model; "gbm" for generalized boosted model; "lasso" for lasso regression; "rpart" for classification tree. The default value is method.psest="glm".

method.pslink

Link function used in estimating the propensity score. Allowable options depend on the specific method.psest value specified. The default value is method.pslink="logit", which, along with method.psest="glm", identifies the default method as logistic regression.

method.whomatch

Options of who to match. Allowable options include conc.contl for matching concurrent control to external control pool; conc.treat for matching treatment to external control pool; conc.all for matching treatment plus concurrent control to external control pool; treat2contl for matching treatment to concurrent control plus external control pool.

method.matching

Matching method. Allowable options include "optimal" for optimal matching; "nearest" for nearest neighbor matching without replacement; "med.optimal" for equally splitting patients in the current trial and taking the median of each subset, followed by 1:1 optimal matching; "med.nearest" for equally splitting patients in the current trial and taking the median of each subset, followed by 1:1 nearest neighbor matching without replacement; "km.optimal" for k-means clustering of patients in the current trial, followed by 1:1 optimal matching; "km.nearest" for k-means clustering of patients in the current trial, followed by 1:1 nearest neighbor matching without replacement; "cm.optimal" for fuzzy c-means clustering of patients in the current trial, followed by 1:1 optimal matching; "cm.nearest" for fuzzy c-means of patients in the current trial, followed by 1:1 nearest neighbor matching without replacement; "boot.optimal" for bootstrap sampling from patients in the current trial, followed by 1:1 optimal matching; "boot.nearest" for bootstrap sampling from patient in the current trial, followed by 1:1 nearest neighbor matching without replacement.

method.psorder

Order that the matching takes place when a nearest neighbor matching is used. Allowable options include "largest", where matching takes place in descending order of propensity score; "smallest", where matching takes place in ascending order of propensity score; "random", where matching takes place in a random order; "data", where matching takes place based on the order of units in the data. The matching order must be specified when using the nearest neighbor matching.

n.boot

Number of bootstrap sampling, which must be specified when method.matching="boot.optimal" or method.matching="boot.nearest". The default value is n.boot=100.

analysis.cov

Vector of names of covariates which are used for the Bayesian analysis with commensurate prior. The names of covariates must be included in lab values specified in cov.C.

method.borrow

List of information borrowing method. "noborrow" uses the concurrent data only. "fullborrow" uses the external control data without discounting. "cauchy" uses the commensurate prior to dynamically borrow the external control data, and the commensurability parameter is assumed to follow a half-Cauchy distribution. "normal" uses the commensurate prior to dynamically borrow the external control data, and the commensurability parameter is assumed to follow a half-normal distribution. "cauchy" and "normal" require to specify the scale parameter scale of half-Cauchy and half-normal distribution respectively.

chains

Number of Markov chains in MCMC sampling. The default value is chains=2.

iter

Number of iterations for each chain (including warmup) in MCMC sampling. The default value is iter=4000.

warmup

Number of warmup (burnin) iterations per chain in MCMC sampling. The default value is warmup=floor(iter/2).

thin

Period for saving samples in MCMC sampling. The default value is thin=1.

alternative

Alternative hypothesis to be tested ("greater" or "less"). The default value is alternative="greater".

sig.level

Significance level. The default value is sig.level=0.025.

nsim

Number of simulated trials.

Details

The simulation study consists of three part: data generation conducted by trial.simulation.bin function, propensity score matching conducted by psmatch function, and Bayesian analysis with commensurate prior conducted by commensurate.bin function. Users can specify different sets of covariates for the propensity score matching and the Bayesian analysis.

Value

The psborrow.bin returns a list containing the following objects:

reject

Data frame containing results of Bayesian one-sided hypothesis testing (whether or not the posterior probability that the log odds ratio is greater or less than 0 exceeds 1 minus significance level): TRUE when significant, otherwise FALSE.

theta

Data frame containing posterior mean, median, and sd of log odds ratio.

ov

Data frame containing (1) overlapping coefficient of propensity score densities between treatment versus concurrent control plus external control and between concurrent control versus external control, (2) overlapping coefficient of continuous covariate densities between treatment versus concurrent control plus external control and between concurrent control versus external control, and (3) rate difference of binary covariate between treatment versus concurrent control plus external control and between concurrent control versus external control.

n.CT

Number of patients in treatment group in the current trial.

n.CC

Number of patients in concurrent control group in the current trial.

n.ECp

Number of patients in external control pool.

n.EC

Number of patients in external control.

drift

Odds ratio between concurrent and external control.

true.theta

True log odds ratio

method.psest

Method of estimating the propensity score.

method.pslink

Link function used in estimating the propensity score.

method.whomatch

Option of who to match.

method.matching

Propensity score matching method.

method.psorder

Order that the matching takes place when a nearest neighbor matching is used.

Examples

n.CT  <- 100
n.CC  <- 50
n.ECp <- 200
n.EC  <- 50

out.prob.CT <- 0.2
out.prob.CC <- 0.2
driftOR     <- 1.0

cov.C <- list(list(dist="norm",mean=0,sd=1,lab="cov1"),
              list(dist="binom",prob=0.4,lab="cov2"))

cov.cor.C <- rbind(c(  1,0.1),
                   c(0.1,  1))

cov.EC <- list(list(dist="norm",mean=0,sd=1,lab="cov1"),
               list(dist="binom",prob=0.4,lab="cov2"))

cov.cor.EC <- rbind(c(  1,0.1),
                    c(0.1,  1))

cov.effect <- c(0.9,0.9)

psmatch.cov <- c("cov1","cov2")

method.whomatch <- "conc.treat"
method.matching <- "optimal"
method.psorder  <- NULL

analysis.cov <- c("cov1")

method.borrow <- list(list(prior="noborrow"),
                      list(prior="normal",scale=0.5))

nsim <- 5

psborrow.bin(
  n.CT=n.CT, n.CC=n.CC, n.ECp=n.ECp, n.EC=n.EC,
  out.prob.CT=out.prob.CT, out.prob.CC=out.prob.CC, driftOR=driftOR,
  cov.C=cov.C, cov.cor.C=cov.cor.C,
  cov.EC=cov.EC, cov.cor.EC=cov.cor.EC, cov.effect=cov.effect,
  psmatch.cov=psmatch.cov, method.whomatch=method.whomatch,
  method.matching=method.matching, method.psorder=method.psorder,
  analysis.cov=analysis.cov, method.borrow=method.borrow,
  chains=1, iter=100, nsim=nsim)

[Package psBayesborrow version 1.1.0 Index]