genRCT | R Documentation |
Provides estimation and inference for the average treatment effect (ATE), generalizing from a randomized controlled trial (RCT) to a target population leveraging observational studies. The method of sieves can be used for the estimation of sampling score and outcome models. The ATE can be estimated with up to 6 methods among the following: Naive, IPSW, AIPSW, CW, ACW-t, ACW-b.
genRCT(
Y.trial,
A.trial,
X.trial,
Y.rwe,
A.rwe,
X.rwe,
family = "gaussian",
estimators = c("Naive", "IPSW", "AIPSW", "CW", "ACW-t", "ACW-b"),
sieve = TRUE,
inference = TRUE,
n.boot = 100,
conf.level = 0.05,
seed = NULL,
plot.boot = TRUE,
verbose = TRUE
)
Y.trial |
Observed outcome from a trial; vector of size |
A.trial |
Treatment received from a trial; vector of size |
X.trial |
Matrix of |
Y.rwe |
Observed outcome from OS; if obtained, vector of size |
A.rwe |
Treatment received from OS; if obtained, vector of size |
X.rwe |
Matrix of |
family |
The type of outcome; |
estimators |
A vector of one or multiple methods to estimate the ATE. Allowed values are
|
sieve |
A logical value indicating whether the method of sieves are used for estimating sampling score and outcome models.
Used only if |
inference |
A logical value indicating whether inference for the ATE via bootstrap should be provided.
Default it |
n.boot |
A numeric value indicating the number of bootstrap samples used. This is only relevant
if |
conf.level |
The level of bootstrap confidence interval; Default is |
seed |
An optional integer specifying an initial randomization seed for reproducibility.
Default is |
plot.boot |
A logical value indicating whether histograms of the bootstrap samples should be produced. Default is |
verbose |
A logical value indicating whether intermediate progress messages should be printed.
Default is |
Return a list containing:
fit |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.