Code for interference regression adjustments
This repository contains code for producing the simulations and figures found in
- A. Chin, Regression adjustments for estimating the global treatment effect in experiments with interference, Journal of Causal Inference, May 2019.
data serve as placeholder folders for the data.
.matfiles from the Facebook100 (FB100) dataset should be placed in the
datafolder. The Facebook100 (FB100) dataset is publicly available from the Internet Archive at https://archive.org/details/oxford-2005-facebook-matrix and other public repositories.
cai-datashould contain data from the paper ``Social networks and the decision to insure'' (2015). The data is available for download from the publication website.
Reproducing results and figures
functionsfolder contains useful helpers and utilities described as follows:
covariate_functions.Rcontains a few sample functions for generating possible interference features. These are the X(W) functions described in the paper.
response_functions.Rgenerates sample outcome models.
data_generators.Rbuilds data frames containing realized samples of the data.
existing_estimators.Rcontains common baseline estimators, such as difference-in-means.
proposed_estimators.Rconstructs the adjustment estimators described in the paper.
variance_estimators.Rbuilds variance estimators for existing and proposed estimators.
precompute_matrices.Rcontains functionality for precomputing certain covariance matrices which are the same for each simulation run.
figuresdirectory contains all figures from the paper.
resultsdirectory is a placeholder location for the simulation output stored as
All remaining top-level files are used to generate the figures:
schematic_networks.Rgenerates Figure 1.
counterfactual_plots.Rgenerates Figure 2.
sim_basic.Rgenerates Table 2.
plot_weights.Rgenerates Figure 3.
- Figures 4 and 5 are generated by
sim_lim_analyze.R, which uses the output from
plot_nonlinear_response.Rgenerates Figure 6.
sim_nonlinear.Rgenerates Table 3.
cai_analyse.Rgenerates Figure 7 and Table 5.