tidy.prop_scr {beastt} | R Documentation |
Tidy a(n) prop_scr object
Description
Tidy a(n) prop_scr object
Usage
## S3 method for class 'prop_scr'
tidy(x, ...)
Arguments
x |
a |
... |
Unused, included for generic consistency only. |
Value
A tidy tibble::tibble()
summarizing the results of the propensity
score weighting. The tibble will have the id column of the external data,
an internal
column to indicate all the data is external, a ps
column
with the propensity scores and a weight
column with the inverse
probability weights
Examples
library(dplyr)
ps_obj <- calc_prop_scr(internal_df = filter(int_binary_df, trt == 0),
external_df = ex_binary_df,
id_col = subjid,
model = ~ cov1 + cov2 + cov3 + cov4)
tidy(ps_obj)
[Package beastt version 0.0.3 Index]