Discovering Latent Treatments in Text Corpora and Estimating Their Causal Effects
Sample from the Fong and Grimmer Wikipedia Biography Data
Infer Treatments on the Test Set
Supervised Indian Buffet Process (sibp) for Discovering Treatments
Infer Treatments on the Test Set
Calculate Exclusivity Metric
Search Parameter Configurations for Supervised Indian Buffet Process (...
Report Words Most Associated with each Treatment
Implements the approach described in Fong and Grimmer (2016) <https://aclweb.org/anthology/P/P16/P16-1151.pdf> for automatically discovering latent treatments from a corpus and estimating the average marginal component effect (AMCE) of each treatment. The data is divided into a training and test set. The supervised Indian Buffet Process (sibp) is used to discover latent treatments in the training set. The fitted model is then applied to the test set to infer the values of the latent treatments in the test set. Finally, Y is regressed on the latent treatments in the test set to estimate the causal effect of each treatment.