Thank you, whuber, for making me aware of Wald's Sequential Probability Ratio Test (SPRT). At your recommendation, I will relist this Quantitative Skills site. They will give you an out-of-the-box table to determine whether to continue or stop testing.
I also took the time to research that site's references, and was directed toward a comprehensive article that is intended for medical testing, but is easily transferable to other domains. It is Increasing Efficiency in Evaluation Research: The Use of Sequential Analysis (Howe, Holly L., American Journal of Public Health July 1982, Vol. 72, No. 7, pp. 690-697.) This article may be downloaded in its entirety.
Since I have not seen SPRT in my stats courses, I will provide a cookbook that I hope will he helpful for the stackexchange community.
For my null hypothesis, I tested for a level of 95% correct. If, however, the level was below 80%, it would be a cause for concern. So I have
$p_1 = .95$ (null hypothesis), and $p_2 = .80$ (alternative hypothesis)
I will use $\alpha = 0.05$ and $\beta = 0.10$.
Howe shows a graph with two parallel lines, with plots of the cumulative errors. Testing continues while the cumulative errors (and in my case, cumulative count of correct data points) lie between the two lines.
If the cumulative errors exceed either line, then either:
- accept the null hypothesis (if cumulative error count falls below the bottom line, $d_1$), or
- reject the null hypothesis (if cumulative error count exceeds the top line, $d_2$).
Here are the equations. I am adding a denominator because it is used several times.
$denom = log\left [ \left ( \frac{p_2}{p_1}\right )(\frac{1 - p_1}{1 - p_2}) \right ]$
The slopes of the lines are the same, and represented by s.
$s = \frac{log\left ( \frac{1 - p_1}{1 - p_2} \right )}{denom}$
The intercepts, $h_1$ and $h_2$, are computed as follows:
$h_1 = \frac{log\left ( \frac{1 - \alpha }{\beta }\right )}{denom}$
$h_2 = \frac{log\left ( \frac{1 - \beta }{\alpha }\right )}{denom}$
I set up a spreadsheet with data point N going from 1 to 50. Then I added two columns for acceptance threshold ($d_1$) and rejection threshold ($d_2$).
$d_1 = -h_1 + sN$
$d_2 = h_2 + sN$
In my experiment,
$denom = -0.67669$
$h_1 = -1.44485$
$h_2 = -1.85501$
The values of $d_1$ at N=2, N=5, N=10 are 3.224, 5.893, 10.342.
I then added columns for success and cumSuccess. I picked data points until the cumulative number exceeded the acceptance threshold, and I accepted the null hypothesis.