Learn R Programming

psrwe (version 3.2)

psrwe_compl: PS-Integrated Composite Likelihood Estimation

Description

Estimate the mean of the outcome based on PS-integrated composite likelihood approach. Variance is estimated by the Jackknife method. Applies to the case when there is only one external data source.

Usage

psrwe_compl(
  dta_psbor,
  v_outcome = "Y",
  outcome_type = c("continuous", "binary"),
  stderr_method = c("jk", "sjk", "cjk", "sbs", "cbs", "none"),
  n_bootstrap = 200,
  ...
)

Value

A data frame with class name PSRWE_RST. It contains the composite estimation of the mean for each stratum as well as the jackknife estimation for each subject. The results can be further summarized by its S3 method summary. The results can also be analyzed by psrwe_outana for outcome analysis and inference.

Arguments

dta_psbor

A class PSRWE_BOR object generated by psrwe_borrow.

v_outcome

Column name corresponding to the outcome.

outcome_type

Type of outcomes: continuous or binary.

stderr_method

Method for computing StdErr, see Details

n_bootstrap

Number of bootstrap samples (for bootstrap stderr)

...

Parameters for rwe_cl

Details

stderr_method include jk as default using the Jackknife method within each stratum, sjk for simple Jackknife method for combined estimates such as point estimates in single-arm or treatment effects in RCT, or cjk for complex Jackknife method including refitting PS model, matching, trimming, calculating borrowing parameters, and combining overall estimates. Note that sjk may take a while longer to finish and cjk will take even much longer to finish. The sbs and cbs is for simple and complex Bootstrap methods.

Examples

Run this code
data(ex_dta)
dta_ps <- psrwe_est(ex_dta,
       v_covs = paste("V", 1:7, sep = ""),
       v_grp = "Group",
       cur_grp_level = "current")
ps_borrow <- psrwe_borrow(total_borrow = 30, dta_ps)
rst       <- psrwe_compl(ps_borrow, v_outcome = "Y_Con")
rst

Run the code above in your browser using DataLab