ps_rf: Fitting Random Forests for Propensity Score

Description Usage Arguments Value References Examples

View source: R/propensity.R

Description

fits random forests before estimating propensity scores

Usage

1

Arguments

formula

an object formula to be fitted. Response should be treatment.

data

optional data frame. REMEMBER that treatment should be TRUE or 1.

...

For additional options of randomForest.

Value

propmod class, a list with model and its name

References

Lee, B. K., Lessler, J., & Stuart, E. A. (2010). Improving propensity score weighting using machine learning. Statistics in Medicine. Statistics in Medicine, 29(3), 337-346. https://doi.org/10.1002/sim.3782

Examples

1
fit <- chemical %>% ps_rf(poisox ~ age + sex, data = .)

ygeunkim/propensityml documentation built on Jan. 1, 2021, 1:44 p.m.