Tutorials › VEE Mathematical Statistics › Power Functions for Composite Alternatives

VEE Mathematical Statistics · Power and Sample Size · Tutorial 653 of 880

Power Functions for Composite Alternatives

Learn to express a test’s rejection probability as a function of the unknown parameter and interpret it across composite hypotheses.

Intermediate 10 min read

What You'll Learn

  • Define a power function for a nonrandomized or randomized test.
  • Derive power by summing or integrating probabilities over the rejection region.
  • Distinguish power at a parameter value from the size of a test for a composite null.
  • Interpret power and Type II error at individual values in a composite alternative.
  • Check monotonicity and avoid common errors in discrete probability calculations.

Why a Power Function Depends on the Parameter

A test is a rule for deciding when observed data provide enough evidence to reject a null hypothesis. Its probability of rejection depends on the distribution that generated the data, and that distribution typically depends on an unknown parameter. For a composite alternative, there is not just one rejection probability: there is a different probability at each parameter value. The function collecting those probabilities is the power function.

For example, a rule that rejects when a count is unusually large may rarely reject when the event probability is small and reject often when it is large. Calculating the rejection probability at a single alternative value describes performance there, but does not describe the test over the full alternative. A power function makes that dependence explicit.

Definition: Let \(X\) denote the observed data, with distribution indexed by a parameter \(\theta\) in a parameter space \(\Theta\). For a nonrandomized test with rejection region \(R\), the power function is $$ \beta(\theta)=P_\theta(X\in R), \qquad \theta\in\Theta. $$ It is the probability that the test rejects at each possible parameter value. For a randomized test with rejection probability \(\phi(x)\) after observing \(x\), where \(0\leq\phi(x)\leq1\), the power function is \(\beta(\theta)=E_\theta[\phi(X)]\).

The power function is defined over the entire parameter space, including parameter values allowed by the null hypothesis and those in the alternative. If the null is simple, \(H_0:\theta=\theta_0\), then \(\beta(\theta_0)\) is the probability of a Type I error for this test. If the null is composite, \(H_0:\theta\in\Theta_0\), the size of the test is the largest rejection probability over the null parameter values:

$$ \operatorname{size}=\sup_{\theta\in\Theta_0}\beta(\theta). $$

A test has significance level at most \(\alpha\) when this supremum is at most \(\alpha\). Consequently, the power at each null value need not equal the size; the size is the largest such probability. At an alternative value \(\theta\in\Theta_1\), the power is the probability of correctly rejecting the null at that value. The corresponding Type II error probability at that particular alternative value is \(1-\beta(\theta)\).

Deriving the Rejection Probability

The calculation follows directly from the definition of probability. In a discrete model, add the probabilities of all data outcomes that lead to rejection. In a continuous model, integrate the density over the rejection region. If a test randomizes, weight each outcome’s probability by its conditional chance of rejection.

Derivation: For discrete data and a nonrandomized test, the events \(X=x\) for distinct values \(x\in R\) are mutually exclusive. Their union is the rejection event. Therefore, by additivity of probability, $$ \beta(\theta)=P_\theta(X\in R)=\sum_{x\in R}P_\theta(X=x). $$ For continuous data with density \(f_\theta\), the same rejection event has probability \(\beta(\theta)=\int_R f_\theta(x)\,dx\). For a randomized rule, condition on the observed data: the conditional rejection probability is \(\phi(x)\), so averaging over the distribution of \(X\) gives \(\beta(\theta)=E_\theta[\phi(X)]\).

The important step is to keep the parameter in the distribution while calculating. The rejection region is fixed by the test rule, but the probabilities of its outcomes change with \(\theta\). That is why the result is a function rather than a single number.

1
State the model and parameter space.
Identify the distribution of the data and all allowable values of \(\theta\).
2
Write the rejection rule.
Specify the rejection region, including any randomization at boundary outcomes.
3
Calculate rejection probability.
Sum, integrate, or take the expected randomized rejection probability, leaving \(\theta\) in the expression.
4
Interpret the function on the hypotheses.
Evaluate or bound it on the null space to find size, and evaluate it on the alternative to assess power.

Worked Examples

Worked Example: A Binomial Test Across Alternative Probabilities

A hypothetical quality-control monitor independently inspects \(5\) units. Let \(X\) be the number with a specified flaw, so \(X\sim\operatorname{Binomial}(5,p)\), where \(p\in[0,1]\) is the flaw probability. The test rejects \(H_0:p=0.2\) when \(X\geq4\). Derive the power function and calculate it at \(p=0.2\), \(0.5\), and \(0.8\).

Method. The rejection outcomes are \(X=4\) and \(X=5\). Under the stated independent Bernoulli model, $$ \beta(p)=P_p(X=4)+P_p(X=5) =\binom54p^4(1-p)+\binom55p^5 =5p^4(1-p)+p^5. $$ Collecting terms gives \(\beta(p)=5p^4-4p^5\).

At the null value \(p=0.2\), \(p^4=0.0016\) and \(p^5=0.00032\). Thus, $$ \beta(0.2)=5(0.0016)(0.8)+0.00032 =0.0064+0.00032=0.00672. $$ The test’s Type I error probability is therefore \(0.00672\), or \(0.0067\) to four decimal places.

At \(p=0.5\), \(p^4=0.0625\) and \(p^5=0.03125\), so $$ \beta(0.5)=5(0.0625)(0.5)+0.03125 =0.15625+0.03125=0.1875. $$ At \(p=0.8\), \(p^4=0.4096\) and \(p^5=0.32768\), giving $$ \beta(0.8)=5(0.4096)(0.2)+0.32768 =0.4096+0.32768=0.73728. $$ Rounded to four decimal places, the powers are \(0.0067\), \(0.1875\), and \(0.7373\), respectively.

Check. Each value is between \(0\) and \(1\), as a probability must be. The rejection rule is aimed at large flaw probabilities, and the calculated rejection probability rises across the three parameter values.

Common mistake avoided. In the expansion \(5p^4-4p^5\), the coefficient multiplies the whole power: \(5(0.2)^4=0.008\), not \(0.0016\), and \(4(0.2)^5=0.00128\), not \(0.00032\). The direct probability calculation above also shows where the binomial coefficient \(\binom54=5\) belongs.

Worked Example: Finding Size for a Composite Poisson Null

A hypothetical monitoring system records the number \(X\) of interruptions during one fixed operating period. Assume \(X\sim\operatorname{Poisson}(\lambda)\), with \(\lambda\geq0\), and reject \(H_0:\lambda\leq1\) when \(X\geq2\). Find the power function, the size of this test, and its power at \(\lambda=0.5\), \(1\), and \(2\).

Method. The test rejects unless \(X=0\) or \(X=1\). Since \(P_\lambda(X=k)=e^{-\lambda}\lambda^k/k!\), $$ \beta(\lambda)=1-P_\lambda(X=0)-P_\lambda(X=1) =1-e^{-\lambda}(1+\lambda). $$ This formula applies for every \(\lambda\geq0\), not only for values in the alternative.

To find the size, check how \(\beta(\lambda)\) behaves over the composite null. Differentiating gives $$ \beta'(\lambda)=\lambda e^{-\lambda}\geq0 \qquad (\lambda\geq0). $$ Thus power is nondecreasing, and its largest value for \(0\leq\lambda\leq1\) occurs at the boundary \(\lambda=1\). The size is $$ \beta(1)=1-\frac{2}{e}\approx0.2642. $$

For \(\lambda=0.5\), \(\beta(0.5)=1-1.5e^{-0.5}\approx1-0.9098=0.0902\). At \(\lambda=1\), the power is approximately \(0.2642\), as above. At \(\lambda=2\), $$ \beta(2)=1-3e^{-2}\approx1-0.4060=0.5940. $$ Probabilities are rounded to four decimal places.

Check. The null power values do not exceed the size, and power increases as the rate increases. The size is the maximum over the whole null space, not the power at an arbitrary null value.

Common mistake avoided. Substituting only the alternative value \(\lambda=2\) gives power, not size. To find size for a composite null, maximize the rejection probability over every null parameter value; here monotonicity identifies the boundary as the maximum.

Worked Example: A Randomized Test With a Composite Alternative

A hypothetical audit inspects \(3\) independent records, each flagged with probability \(p\), so \(X\sim\operatorname{Binomial}(3,p)\) for \(p\in[0,1]\). The test rejects \(H_0:p\leq0.2\) whenever \(X=3\), and rejects with probability \(1/2\) when \(X=2\). Find its power function, its size, and its power at \(p=0.5\) and \(p=0.8\).

Method. The conditional rejection probability is \(1\) at \(X=3\), \(1/2\) at \(X=2\), and \(0\) otherwise. Therefore, $$ \beta(p)=P_p(X=3)+\frac12P_p(X=2) =p^3+\frac12\binom32p^2(1-p) =p^3+\frac32p^2(1-p) =\frac32p^2-\frac12p^3. $$

For \(0\leq p\leq1\), the derivative is $$ \beta'(p)=3p-\frac32p^2=\frac32p(2-p)\geq0. $$ The power is nondecreasing, so the maximum over the null interval \(0\leq p\leq0.2\) occurs at \(p=0.2\). There, \(P(X=3)=0.2^3=0.008\), while \(P(X=2)=3(0.2)^2(0.8)=0.096\). Hence $$ \operatorname{size}=\beta(0.2)=0.008+\frac12(0.096)=0.056. $$

At \(p=0.5\), \(P(X=3)=0.125\) and \(P(X=2)=3(0.25)(0.5)=0.375\), so \(\beta(0.5)=0.125+0.5(0.375)=0.3125\). At \(p=0.8\), \(P(X=3)=0.512\) and \(P(X=2)=3(0.64)(0.2)=0.384\), giving \(\beta(0.8)=0.512+0.5(0.384)=0.704\).

Check. The size \(0.056\) is the rejection probability at the largest null value, not the probability of rejecting at every null value. The alternative values have greater power, consistent with the increasing function.

Common mistake avoided. The test does not always reject when \(X=2\). Counting all of \(P(X=2)\) would replace the specified factor \(1/2\) with \(1\) and overstate the power.

Reading the Function Across the Hypotheses

A power function answers a pointwise question: if the parameter were \(\theta\), how likely would this test be to reject? For a composite alternative, power can differ substantially among its values. A test may have high power for alternatives far from the null and low power for alternatives close to it. A statement such as “the test has power \(0.8\)” is incomplete unless it identifies the parameter value, or specifies a summary over a set of values.

The shape of the function depends on both the sampling distribution and the rejection rule. A rule that rejects for large counts often produces increasing power as the event probability or rate increases. A two-sided rule, however, may have power that is largest at parameter values far from the null in either direction, rather than increasing in one direction over the whole parameter space. Monotonicity should be established from the formula or the model; it should not be assumed from the word “power.”

Parameter valuesMeaning of \(\beta(\theta)\)How it is used
\(\theta\in\Theta_0\)Probability of rejecting at a null valueThe supremum over the null space is the test’s size
\(\theta\in\Theta_1\)Probability of correctly rejecting at an alternative valueIts complement is the Type II error probability at that value
Any \(\theta\in\Theta\)Rejection probability under the distribution indexed by \(\theta\)Describes test behavior over the full parameter space

For a composite null, some null values may have rejection probabilities below the size. For a composite alternative, there is no single Type II error probability unless a particular alternative value is specified. These distinctions matter when comparing a test’s performance or checking whether its rejection rule meets a stated significance level.

Common Errors to Avoid

  • Dropping the parameter. A rejection probability calculated only at one alternative value is one point on the power function, not the function itself.
  • Confusing size with null power at every value. For a composite null, size is the supremum of the power function over the null space. It need not be attained at every null parameter value.
  • Adding outcomes outside the rejection region. Sum only probabilities of outcomes that trigger rejection; for a randomized rule, include each outcome’s rejection probability as a weight.
  • Using the alternative to calculate size. Size is determined by null parameter values. Power at an alternative value is a separate calculation.
  • Assuming power must increase everywhere. The direction and shape depend on the rejection region and the model; verify them rather than inferring them from the test’s purpose.
Key takeaway: Write the test rule first, then calculate its rejection probability as a function of the parameter. The maximum of that function over a composite null gives the size; its value at each alternative parameter gives pointwise power.

Check Your Understanding

For each problem, derive the relevant rejection probability before evaluating it.

  1. Let \(X\sim\operatorname{Binomial}(4,p)\), \(0\leq p\leq1\), and reject when \(X\geq3\). What is the power at \(p=0.25\)? (Answer: \(0.0508\), to four decimal places.)
  2. Let \(X\sim\operatorname{Poisson}(\lambda)\), \(\lambda\geq0\), and reject when \(X\geq1\). For the composite null \(H_0:\lambda\leq0.2\), find the size, and also find power at \(\lambda=0.7\). (Answer: size \(1-e^{-0.2}\approx0.1813\); power at \(0.7\) is \(1-e^{-0.7}\approx0.5034\).)
  3. Let \(X\sim\operatorname{Binomial}(5,p)\). Reject when \(X=5\), and reject with probability \(1/2\) when \(X=4\). At the null value \(p=0.1\), what is the rejection probability? (Answer: \(0.00001+\frac12(5(0.1)^4(0.9))=0.000235\).)
  4. Let \(X\sim\operatorname{Poisson}(\lambda)\) and reject when \(X\geq3\). Find power at \(\lambda=2\). (Answer: \(1-e^{-2}(1+2+2)=1-5e^{-2}\approx0.3233\).)
  5. Let \(X\sim\operatorname{Binomial}(4,p)\), and reject when \(X=0\) or \(X=4\). Find the power at \(p=0.5\) and \(p=0.2\). (Answer: \(\beta(0.5)=0.125\) and \(\beta(0.2)=0.4112\).)
Clinical Biostats