propensity_score: propensity_score

Description Usage Arguments Value

View source: R/propensity_score.R

Description

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.

Usage

1
propensity_score(x_mat, treat_vec, propensity_list = gen_propensity_list())

Arguments

x_mat

Standard input matrix (already rank adjusted).

treat_vec

Usual 0/1 treatment vector.

propensity_list

See gen_propensity_list

Value

Returns a vector equal in length to treat_vec of propensity score.


rzgross/uRbanmatching documentation built on Dec. 22, 2021, 8:20 p.m.