Doubly Robust Estimation Using Joffe's Doubly Robust Weighted Least Squares (DR-WLS) Estimator
Source:R/dr_joffe.R
dr_joffe.Rd
Doubly robust estimators provide a consistent estimate of their target if either the outcome model or censoring model are correctly specified.
Usage
dr_joffe(
data,
outcome_formula,
outcome_family,
treatment_formula,
missing_formula,
missing_family = quasibinomial,
estimand = c("difference", "ratio", "oddsratio")[1],
se_method = c("none", "bootstrap")[1],
alpha = 0.05,
bootstrap_parameters = bootstrap_parameters(),
bootstrap_ci_method = "bca",
verbose = FALSE
)
dr_joffe_fit(
data,
outcome_formula,
outcome_family,
treatment_column,
missing_formula,
missing_family = quasibinomial,
missing_column,
predictors,
estimand = c("difference", "ratio", "oddsratio")[1],
verbose = FALSE
)
Arguments
- data
A
data.frame
- outcome_formula
A
formula
for the outcome model - passed toglm
- outcome_family
A
family
for the outcome model - passed toglm
- treatment_formula
A
formula
: the left-hand side should be a binary variable indicating assignment to treatment, and the right-hand side should be an intercept (e.g.tx ~ 1
)- missing_formula
A
formula
for the censoring model - passed toglm
- missing_family
A
family
for the censoring model - passed toglm
- estimand
A
character
scalar specifying the estimate to compute, such as"difference"
,"ratio"
,"oddsratio"
- se_method
A
character
scalar indicating how standard errors and confidence intervals should be calculated: "none" only computes the estimate, the "sandwich" method use asymptotic variance estimates.- alpha
A
numeric
scalar, indicating the Type I error rate (1 - Confidence Level)- bootstrap_parameters
A
list
of arguments to be passed toboot
for computing the bootstrap.- bootstrap_ci_method
A
character
vector, indicating the method(s) used for computing confidence intervals. Seeboot.ci
for details.- verbose
A
logical
scalar: should just the estimate be returned (FALSE
), or should alist
be returned, containing intermediate results (TRUE
)? Defaults toFALSE
.- treatment_column
A
character
scalar containing the name of the treatment assignment variable- missing_column
A
character
scalar containing the name of the outcome missingness indicator variable- predictors
A
character
vector containing the name of covariates in either the outcome or censoring models.