This function uses equation (6) in Section S.1.2 of the supplementary material to calculate true interaction effects of covariates and treatments on the outcome for subjects in the simulated datasets.

delta.true(X, group, shift_func = shift)

Arguments

X

A covariate matrix of subjects.

group

A vector of group memberships of subjects.

shift_func

A function for the method used in equation (6) to obtain different true interaction effects for subjects in different groups.

Value

A matrix of true propensity scores. Each row represents each subject. Each column represents the interaction effects of covaraites and each treatment.