GetSimData: Simulating the treatment assignment for interference data.

View source: R/GetSimData_function.R

GetSimDataR Documentation

Simulating the treatment assignment for interference data.

Description

Simulating the treatment assignment for interference data.

Usage

GetSimData(dta, pot_out, neigh_ind, re_sd, trt_coef)

Arguments

dta

A data frame including the following variables: neigh varying from 1 to the number of neighborhoods, and two covariates X1 and X2.

pot_out

A list of length equal to the number of clusters. Each element is an array of 3 dimensions. Element ijk of the array is the potential outcome for unit i in the cluster if the treatment of unit is j - 1 and k - 1 of neighbors are treated.

neigh_ind

A list of length equal to the number of custers including the row indices corresponding to each cluster.

re_sd

The standard deviation of the cluster specific random effect for the propensity score model. If set to 0, the propensity score model includes only fixed effects.

trt_coef

Coefficients of the propensity score model corresponding to the intercept, and the two covariates in dta.


gpapadog/Interference documentation built on Oct. 30, 2022, 9:20 p.m.