This function uses equation (2) in Section S.1.1 of the supplementary material
to calculate true propensity scores for subjects in the simulated datasets.
pi.true(X, K)
| X | a covariate matrix of subjects. |
|---|---|
| K | the number of treatments. |
A matrix of true propensity scores of assigning each subject (row) to each treatment (column).