Description Usage Arguments Value
View source: R/propensity_score.R
Calculates propensity scores for a given matrix and treatment vector. Takes in an input matrix and a treatment vector, along with a function that makes predictions (default xgboost method given) and returns a predicted probability of treatment for each unit, either using in-sample or out-of-sample fits.
1 | propensity_score(x_mat, treat_vec, propensity_list = gen_propensity_list())
|
x_mat |
Standard input matrix (already rank adjusted). |
treat_vec |
Usual 0/1 treatment vector. |
propensity_list |
See |
Returns a vector equal in length to treat_vec of propensity score.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.