Randomization inference with Stata: A guide and software
收藏资源简介:
Randomization inference or permutation tests are only sporadically used in economics and other social sciences—this despite a steep increase in randomization in field and laboratory experiments that provide perfect experimental setups for applying randomization inference. In the context of causal inference, such tests can handle problems often faced by applied researchers, including issues arising in the context of small samples, stratified or clustered treatment assignments, or nonstandard randomization techniques. Standard statistical software packages have either no implementation of randomization tests or very basic implementations. Whenever researchers use randomization inference, they regularly code individual program routines, risking inconsistencies and coding mistakes. In this article, I show how randomization inference can best be conducted in Stata and introduce a new command, ritest, to simplify such analyses. I illustrate this approach’s usefulness by replicating the results in Fujiwara and Wantchekon (2013, American Economic Journal: Applied Economics 5: 241–255) and running simulations. The applications cover clustered and stratified assignments, with varying cluster sizes, pairwise randomization, and the computation of nonapproximate p-values. The applications also touch upon joint hypothesis testing with randomization inference.
随机化推断(randomization inference)或置换检验(permutation tests)在经济学与其他社会科学中的应用仍较为零散——尽管当前实地实验与实验室实验中的随机化应用已大幅增加,而此类实验恰好为随机化推断的应用提供了完美的实验框架。在因果推断的语境下,此类检验能够处理应用研究者常面临的诸多问题,包括小样本场景、分层或集群处理分配,以及非标准随机化技术所引发的各类问题。主流统计软件包要么未实现随机化检验功能,要么仅提供极为基础的实现方案。每当研究者开展随机化推断相关工作时,往往需要自行编写独立的程序脚本,这存在代码不一致与编码出错的风险。本文阐述了在Stata软件中开展随机化推断的最优方法,并推出了一款全新命令`ritest`以简化此类分析。通过复现Fujiwara与Wantchekon(2013,《美国经济期刊:应用经济学》(American Economic Journal: Applied Economics)第5卷:241–255)中的研究结果并开展模拟实验,本文展示了该方法的实用性。本次应用场景涵盖了集群与分层分配(集群规模各异)、成对随机化,以及非近似p值的计算,同时也涉及基于随机化推断的联合假设检验。




