Description Usage Arguments Value Examples

`ACER`

tests (two-sided) if the average cluster effect
ratio (ACER) is equal to lambda.

1 2 3 4 5 6 7 8 9 10 11 12 13 |

`num_t` |
A length-K vector where K is equal to the number of clusters and the kth entry equal to the number of units in the encouraged cluster of the kth matched pair of two clusters. |

`num_c` |
A length-K vector with the kth entry equal to the number of units in the control cluster of the kth matched pair of two clusters. |

`R_t` |
A length-K vector with kth entry equal to the sum of unit-level outcomes in the encouraged cluster of the kth matched pair of two clusters. |

`R_c` |
A length-K vector with the kth entry equal to the sum of unit-level outcomes in the control cluster of the kth matched pair of two clusters. |

`d_t` |
A length-K vector with the kth entry equal to the sum of unit-level treatment received in the encouraged cluster of the kth matched pair of two clusters. |

`d_c` |
A length-K vector with the kth entry equal to the sum of unit-level treatment received in the control cluster of the kth matched pair of two clusters. |

`lambda` |
The magnitude of the average cluster effect ratio (ACER) to be tested. |

`alpha` |
The level of the test. |

`kappa` |
Minimum compliance rate. |

`gap` |
Relative MIP optimality gap. |

`verbose` |
If true, the solver output is enabled; otherwise, the solver output is disabled. |

A list of three elements: the optimal solution, the optimal objective value, and an indicator of whether or not the test is rejected.

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 | ```
## Not run:
# To run the following example, Gurobi must be installed.
R_t = encouraged_clusters$aggregated_outcome
R_c = control_clusters$aggregated_outcome
d_t = encouraged_clusters$aggregated_treatment
d_c = control_clusters$aggregated_treatment
num_t = encouraged_clusters$number_units
num_c = control_clusters$number_units
# Test at level 0.05 if the ACER is equal
# to 0.2. Assume the minimum compliance rate across
# K clusters is at least 0.2. Set verbose = FALSE
# to suppress the output.
res = ACER(num_t, num_c, R_t, R_c, d_t, d_c,
lambda = 0.2, alpha = 0.05, kappa = 0.2,
verbose = FALSE)
# The test is rejected
res$Reject
## End(Not run)
``` |

Embedding an R snippet on your website

Add the following code to your website.

For more information on customizing the embed code, read Embedding Snippets.