Estimating the probability of the binomial distribution is a basic problem, which appears in almost all introductory statistics courses and is performed frequently in various studies. In some cases, the parameter of interest is a difference between two probabilities, and the current work studies the construction of confidence intervals for this parameter when the sample size is small. Our goal is to find the shortest confidence intervals under the constraint of coverage probability being larger than a predetermined level. For the two-sample case, there is no known algorithm that achieves this goal, but different heuristics procedures have been suggested, and the present work aims at finding optimal confidence intervals. In the one-sample case, there is a known algorithm that finds optimal confidence intervals presented by Blyth and Still (1983). It is based on solving small and local optimization problems and then using an inversion step to find the global optimum solution. We show that this approach fails in the two-sample case and therefore, in order to find optimal confidence intervals, one needs to solve a global optimization problem, rather than small and local ones, which is computationally much harder. We present and discuss the suitable global optimization problem. Using the Gurobi package we find near-optimal solutions when the sample sizes are smaller than 15, and we compare these solutions to some existing methods, both approximate and exact. We find that the improvement in terms of lengths with respect to the best competitor varies between 1.5\% and 5\% for different parameters of the problem. Therefore, we recommend the use of the new confidence intervals when both sample sizes are smaller than 15. Tables of the confidence intervals are given in the Excel file in this link.
翻译:估计二项分布的概率是一个基础性问题,几乎出现在所有统计学入门课程中,并在各类研究中频繁使用。在某些情况下,关注的参数是两个概率之间的差异,而本研究探讨的是当样本量较小时,该参数的置信区间构造问题。我们的目标是在覆盖概率大于预设水平的约束下,找到最短的置信区间。对于双样本情形,尚无已知算法能实现此目标,但已有多种启发式方法被提出,而本研究旨在寻找最优置信区间。在单样本情形下,存在已知算法(由Blyth和Still于1983年提出)可找到最优置信区间。该算法基于求解小型局部优化问题,然后通过反演步骤得到全局最优解。我们证明该方法在双样本情形下失效,因此,要找到最优置信区间需要求解全局优化问题而非小型局部问题,这在计算上要困难得多。我们提出并讨论了合适的全局优化问题。利用Gurobi软件包,我们在样本量小于15时找到了近优解,并将这些解与现有的一些近似方法及精确方法进行了比较。我们发现,相对于最佳竞品方法,新置信区间在长度上的改进根据问题参数不同在1.5%至5%之间。因此,我们建议在双样本量均小于15时使用这些新置信区间。置信区间表参见此链接中的Excel文件。