- The book defines, given m and n, alpha(p) = Sum[binomial(n, p, k)], k = m, ..., n.
The user enters into this program nullp (the null hypthesis p-value) and an altp
(an alternative hypothesis p, greater than nullp). The program then defines pmin
= nullp - Abs[altp - nullp] and pmax = altp + Abs[altp - nullp], and plots alpha(p)
on the interval [pmin, pmax] for each value m in mlist, with n equal to the
parameter n. The program displays all of these graphs together on a single set
of axes, along with a dotted-line box, whose edges are decided as follows: we
ultimately want each of the probabilities of a type 1or type 2 error occurring to be
<= errormax. The box the program draws is such that a value of m satisfies this
requirement if and only if the graph of alpha(p) enters the box from the bottom
and leaves from the top (see book for more details).