Lecture 22 Hypothesis Testing

In this lecture we turn from estimation to the second question from lecture 1: are the data compatible with a given claim about θ\theta? We first set up the language of hypothesis testing, which lectures 23, 25, 26 and 31 build on, and then construct two tests for the mean of a normal sample.

22.1 Hypotheses

Throughout, X1,…,XnX_{1},\dots,X_{n} follow a parametric model in the sense of definition 1.1. Questions such as whether a coin is fair or whether a treatment has an effect ask whether the true value of θ\theta belongs to a subset of the parameter space Θ\Theta.

Definition 22.1.

A hypothesis is a statement of the form θ∈Θ′\theta\in\Theta^{\prime} for a subset Θ′⊆Θ\Theta^{\prime}\subseteq\Theta. In a testing problem, the null hypothesis H0:θ∈Θ0H_{0}\colon\theta\in\Theta_{0} and the alternative hypothesis H1:θ∈Θ1H_{1}\colon\theta\in\Theta_{1} are given, where Θ0\Theta_{0} and Θ1\Theta_{1} are disjoint subsets of Θ\Theta. A hypothesis is called simple, if the corresponding subset consists of a single point, and composite otherwise.

From now on we write θ0\theta_{0} for the value of θ\theta named by a null hypothesis. In lectures 16 and 17 the same symbol denoted the true value of the parameter; the context makes clear which meaning is intended.

Often we have Θ1=Θ∖Θ0\Theta_{1}=\Theta\setminus\Theta_{0}, and then exactly one of the two hypotheses is true. For example, for the mean θ\theta of a normal sample, the hypothesis H0:θ=θ0H_{0}\colon\theta=\theta_{0} is simple, whereas the one-sided alternative H1:θ>θ0H_{1}\colon\theta>\theta_{0}, the two-sided alternative H1:θ≠θ0H_{1}\colon\theta\neq\theta_{0} and the one-sided null hypothesis H0:θ≤θ0H_{0}\colon\theta\leq\theta_{0} are all composite.

The two hypotheses have different roles: the null hypothesis is the default position, and the alternative is the claim which requires evidence before we can act on it. Section 22.3 makes this distinction precise.

22.2 Tests, Critical Regions and Errors

A test decides between the two hypotheses, and can be described by the set of data values where it rejects H0H_{0}.

Definition 22.2.

A test of H0H_{0} against H1H_{1} is a rule which for every possible data vector x=(x1,…,xn)x=(x_{1},\dots,x_{n}) decides whether to “reject H0H_{0}” or “do not reject H0H_{0}”. The set

C={x|the test rejects H0 for the data x}C=\bigl{\{}\,x\mathrel{\big{|}}\text{the test rejects $H_{0}$ for the data $x$% }\,\bigr{\}}

is called the critical region (or rejection region) of the test. Alternatively, a test can be described by its test function φ⁢(x)=1\varphi(x)=1 for x∈Cx\in C and φ⁢(x)=0\varphi(x)=0 otherwise.

In practice, the critical region usually has the form C={x∣T⁢(x)>c}C=\{x\mid T(x)>c\} or C={x∣T⁢(x)≥c}C=\{x\mid T(x)\geq c\} for a statistic TT given by definition 1.3, called the test statistic, and a constant cc called the critical value. The two forms give tests with different error probabilities only if T⁢(X)=cT(X)=c has positive probability, as can happen for discrete distributions (exercise 22.3).

A test can decide wrongly in two different ways.

Definition 22.3.

A type I error occurs, if the test wrongly rejects H0H_{0} when H0H_{0} is true. A type II error occurs, if the test wrongly does not reject H0H_{0} when H1H_{1} is true.

Table 22.1 summarises the four possible outcomes.

do not reject H0H_{0} reject H0H_{0}
H0H_{0} true correct decision type I error
H1H_{1} true type II error correct decision
Table 22.1: The four possible outcomes of a test.

As an example, in a criminal trial the null hypothesis is the innocence of the defendant, and the alternative is guilt. Convicting an innocent person is a type I error, and acquitting a guilty person is a type II error. Under the standard of proof “beyond reasonable doubt”, many acquittals of the guilty are accepted to avoid wrongful convictions, because a type I error is more serious. Since an acquittal does not prove innocence, the table says “do not reject H0H_{0}” instead of “accept H0H_{0}”.

22.3 The Power Function, Size and Level

Both error probabilities depend on the true parameter value, and can be read off a single function of θ\theta.

Definition 22.4.

The power function of a test with critical region CC is given by

β⁢(θ)=ℙθ⁢(X∈C)=𝔼θ⁢(φ⁢(X)),θ∈Θ,\beta(\theta)=\mathbb{P}_{\theta}(X\in C)=\mathbb{E}_{\theta}\bigl{(}\varphi(X% )\bigr{)},\qquad\theta\in\Theta,

i.e. the probability of rejecting H0H_{0} when the true parameter value is θ\theta. For θ∈Θ1\theta\in\Theta_{1} the value β⁢(θ)\beta(\theta) is called the power of the test at the alternative θ\theta.

For θ∈Θ0\theta\in\Theta_{0} the value β⁢(θ)\beta(\theta) is the probability of a type I error, and for θ∈Θ1\theta\in\Theta_{1} the value 1−β⁢(θ)1-\beta(\theta) is the probability of a type II error (some books write β\beta for the latter). Enlarging the critical region can only increase β⁢(θ)\beta(\theta), which reduces type II errors at the cost of type I errors, and thus we have to choose which probability to control. Since a type I error abandons the default position without good reason, we restrict its probability first and only then consider the power of the test.

Definition 22.5.

The size of a test with power function β\beta is given by

supθ∈Θ0β⁢(θ),\sup_{\theta\in\Theta_{0}}\beta(\theta),

For α∈(0,1)\alpha\in(0,1), the test is a level α\alpha test, if the size of the test is less than or equal to α\alpha.

For a simple null hypothesis H0:θ=θ0H_{0}\colon\theta=\theta_{0}, the size of the test equals β⁢(θ0)\beta(\theta_{0}). The number α\alpha is called the significance level and the values 0.050.05 and 0.010.01 are only conventions. Among all level α\alpha tests, we prefer the test with the largest power at the alternatives. Lecture 23 shows how to find the most powerful test when both hypotheses are simple.

22.4 Testing the Mean of a Normal Sample

We now construct tests for X1,…,XnX_{1},\dots,X_{n} i.i.d. N⁢(θ,σ2)N(\theta,\sigma^{2}) with known variance σ2\sigma^{2}. We write Φ\Phi for the standard normal distribution function and zqz_{q} for the qq-quantile of the standard normal distribution, i.e. we have Φ⁢(zq)=q\Phi(z_{q})=q. The most commonly used quantiles are z0.95=1.645z_{0.95}=1.645 and z0.975=1.96z_{0.975}=1.96.

Example 22.6.

We want to test H0:θ=θ0H_{0}\colon\theta=\theta_{0} against H1:θ>θ0H_{1}\colon\theta>\theta_{0} at significance level α\alpha. Since a value of X¯\bar{X} much larger than θ0\theta_{0} is evidence against H0H_{0}, we use X¯\bar{X} as the test statistic and reject if X¯≥c\bar{X}\geq c. By proposition A.4, under H0H_{0} the standardised mean n⁢(X¯−θ0)/σ\sqrt{n}\,(\bar{X}-\theta_{0})/\sigma is standard normally distributed, and thus the probability of a type I error is

β⁢(θ0)=ℙθ0⁢(X¯≥c)=ℙθ0⁢(n⁢(X¯−θ0)σ≥n⁢(c−θ0)σ)=1−Φ⁢(n⁢(c−θ0)σ).\beta(\theta_{0})=\mathbb{P}_{\theta_{0}}(\bar{X}\geq c)=\mathbb{P}_{\theta_{0% }}\Bigl{(}\frac{\sqrt{n}\,(\bar{X}-\theta_{0})}{\sigma}\geq\frac{\sqrt{n}\,(c-% \theta_{0})}{\sigma}\Bigr{)}=1-\Phi\Bigl{(}\frac{\sqrt{n}\,(c-\theta_{0})}{% \sigma}\Bigr{)}.

Setting this probability equal to α\alpha, we find the critical value as n⁢(c−θ0)/σ=z1−α\sqrt{n}\,(c-\theta_{0})/\sigma=z_{1-\alpha} and thus the resulting test rejects H0H_{0} if

X¯≥θ0+z1−α⁢σn,equivalently ifZ=n⁢(X¯−θ0)σ≥z1−α.\bar{X}\geq\theta_{0}+z_{1-\alpha}\,\frac{\sigma}{\sqrt{n}},\qquad\text{% equivalently if}\qquad Z=\frac{\sqrt{n}\,(\bar{X}-\theta_{0})}{\sigma}\geq z_{% 1-\alpha}.

This is the one-sided zz-test. To determine its power, we let δ=n⁢(θ−θ0)/σ\delta=\sqrt{n}\,(\theta-\theta_{0})/\sigma. Since n⁢(X¯−θ)/σ\sqrt{n}\,(\bar{X}-\theta)/\sigma is standard normally distributed under ℙθ\mathbb{P}_{\theta}, and since 1−Φ⁢(x)=Φ⁢(−x)1-\Phi(x)=\Phi(-x) by the symmetry of the normal distribution, the power function is

equation (22.1) (22.1)
β⁢(θ)=ℙθ⁢(n⁢(X¯−θ)σ≥z1−α−δ)=Φ⁢(δ−z1−α).\beta(\theta)=\mathbb{P}_{\theta}\Bigl{(}\frac{\sqrt{n}\,(\bar{X}-\theta)}{% \sigma}\geq z_{1-\alpha}-\delta\Bigr{)}=\Phi(\delta-z_{1-\alpha}).

The left-hand panel of figure 22.1 shows this function. As nn increases the curve gets steeper, and exercise 22.1 uses this to determine the required sample size.

For n=25n=25, σ=2\sigma=2, θ0=10\theta_{0}=10 and α=0.05\alpha=0.05 the test rejects if X¯≥10+1.645⋅2/5=10.658\bar{X}\geq 10+1.645\cdot 2/5=10.658. At the alternative θ=11\theta=11 we have δ=2.5\delta=2.5 and the power is Φ⁢(2.5−1.645)=Φ⁢(0.855)=0.804\Phi(2.5-1.645)=\Phi(0.855)=0.804, at θ=10.5\theta=10.5 it is only Φ⁢(1.25−1.645)=Φ⁢(−0.395)=0.346\Phi(1.25-1.645)=\Phi(-0.395)=0.346: a shift of a quarter of a standard deviation is detected in barely a third of all samples.

The values θ<θ0\theta<\theta_{0} belong to neither hypothesis of this example. Since the power function (22.1) is increasing, the test also has size supθ≤θ0β⁢(θ)=β⁢(θ0)=α\sup_{\theta\leq\theta_{0}}\beta(\theta)=\beta(\theta_{0})=\alpha for the composite null hypothesis H0:θ≤θ0H_{0}\colon\theta\leq\theta_{0}, which covers these values. This is why definition 22.5 takes a supremum.

Example 22.7.

To detect departures in both directions, we test H0:θ=θ0H_{0}\colon\theta=\theta_{0} against H1:θ≠θ0H_{1}\colon\theta\neq\theta_{0} and we reject for |X¯−θ0|≥c|\bar{X}-\theta_{0}|\geq c. Since Z=n⁢(X¯−θ0)/σZ=\sqrt{n}\,(\bar{X}-\theta_{0})/\sigma is standard normally distributed under H0H_{0} and the normal distribution is symmetric, we have

ℙθ0⁢(|X¯−θ0|≥c)=ℙθ0⁢(|Z|≥n⁢cσ)=2⁢(1−Φ⁢(n⁢cσ)).\mathbb{P}_{\theta_{0}}\bigl{(}|\bar{X}-\theta_{0}|\geq c\bigr{)}=\mathbb{P}_{% \theta_{0}}\Bigl{(}|Z|\geq\frac{\sqrt{n}\,c}{\sigma}\Bigr{)}=2\Bigl{(}1-\Phi% \Bigl{(}\frac{\sqrt{n}\,c}{\sigma}\Bigr{)}\Bigr{)}.

Setting this equal to α\alpha, we find n⁢c/σ=z1−α/2\sqrt{n}\,c/\sigma=z_{1-\alpha/2} and thus the two-sided zz-test rejects H0H_{0} if

|X¯−θ0|≥z1−α/2⁢σn,equivalently if|Z|≥z1−α/2.|\bar{X}-\theta_{0}|\geq z_{1-\alpha/2}\,\frac{\sigma}{\sqrt{n}},\qquad\text{% equivalently if}\qquad|Z|\geq z_{1-\alpha/2}.

With δ\delta as in example 22.6, the same standardisation gives the power function

β⁢(θ)=Φ⁢(−z1−α/2−δ)+Φ⁢(δ−z1−α/2),\beta(\theta)=\Phi(-z_{1-\alpha/2}-\delta)+\Phi(\delta-z_{1-\alpha/2}),

shown in the right-hand panel of figure 22.1. This function is symmetric about θ0\theta_{0} and has its minimum value α\alpha at this point (exercise 22.2). For n=25n=25, σ=2\sigma=2, θ0=10\theta_{0}=10 and α=0.05\alpha=0.05 the test rejects if |X¯−10|≥1.96⋅2/5=0.784|\bar{X}-10|\geq 1.96\cdot 2/5=0.784 and at θ=11\theta=11 we have δ=2.5\delta=2.5 and the power Φ⁢(−4.46)+Φ⁢(0.54)=0.705\Phi(-4.46)+\Phi(0.54)=0.705.

Two panels showing power against theta, for theta
from 8 to 12. Left panel, one-sided test: S-shaped curves which
are close to 0 below theta = 10, pass through 0.05 at theta = 10
and rise to 1; the curve for n = 100 rises more steeply than the
curve for n = 25. Right panel, two-sided test: U-shaped curves,
symmetric about theta = 10, with minimum 0.05 at theta = 10 and
close to 1 at both ends; again the curve for n = 100 is the
steeper one. A dotted horizontal line marks the value 0.05.
Figure 22.1: Power functions of the one-sided zz-test (left) and the two-sided zz-test (right) of H0:θ=10H_{0}\colon\theta=10 at level 0.050.05, for σ=2\sigma=2 and the sample sizes n=25n=25 (solid) and n=100n=100 (dashed).

At θ=11\theta=11 the one-sided test has power 0.8040.804 against 0.7050.705, since it places all of its type I error probability in the upper tail, but it is useless for alternatives below θ0\theta_{0}. Lecture 23 shows that the one-sided test is most powerful against every alternative above θ0\theta_{0}, and that no single test is best for both directions. Thus, before we consider the data, we must decide which departures from H0H_{0} are of interest.

22.5 The pp-Value

A test at a fixed level only states whether H0H_{0} is rejected. The pp-value also records how extreme the observed value of the test statistic is under H0H_{0}.

Definition 22.8.

For a test which rejects H0H_{0} for large values of a test statistic TT, the pp-value of the data xx is given by

equation (22.2) (22.2)
p⁢(x)=supθ∈Θ0ℙθ⁢(T⁢(X)≥T⁢(x)).p(x)=\sup_{\theta\in\Theta_{0}}\mathbb{P}_{\theta}\bigl{(}T(X)\geq T(x)\bigr{)}.

For a test which rejects for small values of TT the inequality is reversed, and the two-sided zz-test uses T=|Z|T=|Z|.

For a simple null hypothesis the supremum reduces to ℙθ0\mathbb{P}_{\theta_{0}}. Since p⁢(x)p(x) is the size of the test with critical region {T≥T⁢(x)}\{T\geq T(x)\}, it is the smallest level at which a test of the form {T≥c}\{T\geq c\} rejects xx, and thus H0H_{0} is rejected at level α\alpha if and only if p⁢(x)≤αp(x)\leq\alpha. In this case we call the data significant at level α\alpha. For the one-sided zz-test we find p⁢(x)=1−Φ⁢(z)p(x)=1-\Phi(z), where z=n⁢(x¯−θ0)/σz=\sqrt{n}\,(\bar{x}-\theta_{0})/\sigma is the observed value of ZZ, and for the two-sided test we find p⁢(x)=2⁢(1−Φ⁢(|z|))p(x)=2\bigl{(}1-\Phi(|z|)\bigr{)}. In the situation of example 22.6, the observed mean x¯=10.9\bar{x}=10.9 gives z=2.25z=2.25 and thus p=1−Φ⁢(2.25)=0.0122p=1-\Phi(2.25)=0.0122 for the one-sided test and p=0.0244p=0.0244 for the two-sided test.

For a simple null hypothesis and a continuous test statistic, the distribution of the pp-value under H0H_{0} does not depend on the model.

Lemma 22.9.

Let H0:θ=θ0H_{0}\colon\theta=\theta_{0} be simple and let T⁢(X)T(X) have a continuous distribution function FF under ℙθ0\mathbb{P}_{\theta_{0}}. Then the pp-value of a test which rejects for large values of TT satisfies ℙθ0⁢(p⁢(X)≤u)=u\mathbb{P}_{\theta_{0}}\bigl{(}p(X)\leq u\bigr{)}=u for all u∈(0,1)u\in(0,1), i.e. it is uniformly distributed on (0,1)(0,1) under H0H_{0}.

Proof.

Fix u∈(0,1)u\in(0,1). Since FF is continuous, we have p⁢(x)=1−F⁢(T⁢(x))p(x)=1-F\bigl{(}T(x)\bigr{)}. Let tt be the smallest number with F⁢(t)=1−uF(t)=1-u, which exists since FF is continuous with limits 0 and 11. Since FF is non-decreasing, p⁢(X)≤up(X)\leq u holds if and only if T⁢(X)≥tT(X)\geq t, and thus ℙθ0⁢(p⁢(X)≤u)=1−F⁢(t)=u\mathbb{P}_{\theta_{0}}\bigl{(}p(X)\leq u\bigr{)}=1-F(t)=u. This completes the proof. ∎

For a discrete test statistic, e.g. the number of successes in a Bernoulli sample, the pp-value takes only countably many values and is not uniformly distributed. For an integer-valued TT, the test which rejects if p⁢(x)≤αp(x)\leq\alpha is the test {T≥c}\{T\geq c\} with the smallest integer cc of level α\alpha, and thus it still has size at most α\alpha. A test whose size is smaller than its level in this way is called conservative.

Since the pp-value is a probability, it is tempting to misread it. It is not the probability that H0H_{0} is true: the parameter θ\theta is a fixed, unknown number, and the probability in (22.2) refers to the data. Nor does a large pp-value establish H0H_{0}, since data compatible with H0H_{0} may be compatible with many alternatives as well: the test from example 22.6 has power only 0.3460.346 at θ=10.5\theta=10.5.

Summary.
  • •
    ​

    A testing problem contrasts a null hypothesis H0:θ∈Θ0H_{0}\colon\theta\in\Theta_{0} against an alternative H1:θ∈Θ1H_{1}\colon\theta\in\Theta_{1}. A hypothesis is simple, if the corresponding subset of Θ\Theta is a single point, and composite otherwise.

  • •
    ​

    A test is given by its critical region CC, typically of the form T⁢(x)≥cT(x)\geq c for a test statistic TT and critical value cc.

  • •
    ​

    Type I errors are cases where H0H_{0} is true but is wrongly rejected by the test, type II errors are cases where H1H_{1} is true but H0H_{0} is not rejected. The power function β⁢(θ)=ℙθ⁢(X∈C)\beta(\theta)=\mathbb{P}_{\theta}(X\in C) gives the probability of type I errors for Θ0\Theta_{0} and the power of the test for Θ1\Theta_{1}.

  • •
    ​

    The size of a test is supΘ0β\sup_{\Theta_{0}}\beta. A level α\alpha test has size at most α\alpha. The level is chosen first, and then the power of the test can be considered.

  • •
    ​

    For the mean of a normal sample with known variance, the one-sided zz-test has an S-shaped power function and the two-sided zz-test a U-shaped one. Before looking at the data, we decide which departures from H0H_{0} are of interest.

  • •
    ​

    The pp-value is the probability under H0H_{0} of a test statistic at least as extreme as the observed one, and H0H_{0} is rejected at level α\alpha if and only if p⁢(x)≤αp(x)\leq\alpha. It is not the probability that H0H_{0} is true, and a large pp-value does not establish H0H_{0}. For a simple null hypothesis and a continuous test statistic, the pp-value is uniformly distributed on (0,1)(0,1) under H0H_{0}.

Exercise 22.1.

Consider the one-sided zz-test from example 22.6, at level α\alpha, and let θ1>θ0\theta_{1}>\theta_{0} be the alternative and 1−γ∈(α,1)1-\gamma\in(\alpha,1) be the target power.

  1. 1.
    ​

    Show that the test has power at least 1−γ1-\gamma at θ1\theta_{1} if and only if

    n≥((z1−α+z1−γ)⁢σθ1−θ0)2.n\geq\Bigl{(}\frac{(z_{1-\alpha}+z_{1-\gamma})\,\sigma}{\theta_{1}-\theta_{0}}% \Bigr{)}^{2}.
  2. 2.
    ​

    For σ=2\sigma=2, θ1−θ0=0.5\theta_{1}-\theta_{0}=0.5, α=0.05\alpha=0.05 and target power 0.90.9 (so that z0.9=1.282z_{0.9}=1.282), determine the smallest sample size which achieves the target power.

  3. 3.
    ​

    How does the required sample size change, when the difference θ1−θ0\theta_{1}-\theta_{0} is halved? What happens when σ\sigma is doubled?

Exercise 22.2.

Consider the two-sided zz-test from example 22.7, with power function β⁢(θ)=g⁢(δ)\beta(\theta)=g(\delta) where g⁢(δ)=Φ⁢(−z−δ)+Φ⁢(δ−z)g(\delta)=\Phi(-z-\delta)+\Phi(\delta-z), z=z1−α/2z=z_{1-\alpha/2} and δ=n⁢(θ−θ0)/σ\delta=\sqrt{n}\,(\theta-\theta_{0})/\sigma.

  1. 1.
    ​

    Show that g⁢(−δ)=g⁢(δ)g(-\delta)=g(\delta) for all δ∈ℝ\delta\in\mathbb{R}, and conclude that β\beta is symmetric about θ0\theta_{0}.

  2. 2.
    ​

    Show that gg is strictly increasing on [0,∞)[0,\infty). Conclude that β\beta has its minimum value α\alpha at θ0\theta_{0}.

Exercise 22.3.

Let X1,…,X10X_{1},\dots,X_{10} be i.i.d. Bernoulli with success probability θ\theta and consider testing H0:θ=1/2H_{0}\colon\theta=1/2 against H1:θ>1/2H_{1}\colon\theta>1/2 using the test which rejects if T=∑iXi≥cT=\sum_{i}X_{i}\geq c for an integer cc.

  1. 1.
    ​

    Write down the size of the test as a function of cc, using the binomial distribution of TT under H0H_{0}.

  2. 2.
    ​

    Determine the smallest cc such that the test has level 0.050.05. Compute the size of the test for this case. Justify your answer by showing that no choice of cc can lead to a size of exactly 0.050.05.

  3. 3.
    ​

    Determine the power of the test from the previous part when θ=0.7\theta=0.7, θ=0.8\theta=0.8 and θ=0.9\theta=0.9. Comment on the capabilities and limitations of the test with ten observations.

  4. 4.
    ​

    Nine successes are observed. Compute the pp-value and state the decision at level 0.050.05.

Exercise 22.4.

Let X1,…,Xn∼Uniform⁢(0,θ)X_{1},\dots,X_{n}\sim\text{Uniform}(0,\theta) be i.i.d. as in example 1.2 and let M=maxi⁡XiM=\max_{i}X_{i}, where the density was found in example 8.9. We test H0:θ=θ0H_{0}\colon\theta=\theta_{0} against H1:θ>θ0H_{1}\colon\theta>\theta_{0}.

  1. 1.
    ​

    Show that ℙθ⁢(M≤m)=(m/θ)n\mathbb{P}_{\theta}(M\leq m)=(m/\theta)^{n} for 0≤m≤θ0\leq m\leq\theta.

  2. 2.
    ​

    Consider the test which rejects if M>cM>c, for a constant c≤θ0c\leq\theta_{0}. Determine the size of this test and the value of cc which makes the size equal to α\alpha.

  3. 3.
    ​

    Determine the power function of the test from the previous part, and evaluate this function at n=5n=5, θ0=1\theta_{0}=1, α=0.05\alpha=0.05 and θ=1.2\theta=1.2.

  4. 4.
    ​

    Consider the second test, which rejects if M>θ0M>\theta_{0}. Show that this test has size 0. Determine the power function of this test and compare the power functions of the two tests. Which of the two tests would you choose and why?

Exercise 22.5.

A sample of size n=16n=16 from N⁢(θ,σ2)N(\theta,\sigma^{2}) with known σ=4\sigma=4 has mean x¯=52.3\bar{x}=52.3. We want to test θ0=50\theta_{0}=50.

  1. 1.
    ​

    Determine the pp-value of the one-sided zz-test with H0:θ=50H_{0}\colon\theta=50 against H1:θ>50H_{1}\colon\theta>50 and state the decisions for 0.050.05 and 0.010.01.

  2. 2.
    ​

    Determine the pp-value of the two-sided test against H1:θ≠50H_{1}\colon\theta\neq 50 and state the same two decisions.

  3. 3.
    ​

    Your colleague summarises the first part of the question as “there is a 1.1%1.1\% chance that the mean is 5050”. What is wrong with this sentence? Write one correct sentence to summarise the first part of the question.

  4. 4.
    ​

    Verify lemma 22.9 directly for the one-sided zz-test: show that under H0H_{0} the pp-value p⁢(X)=1−Φ⁢(Z)p(X)=1-\Phi(Z) with Z=n⁢(X¯−θ0)/σZ=\sqrt{n}\,(\bar{X}-\theta_{0})/\sigma satisfies ℙθ0⁢(p⁢(X)≤u)=u\mathbb{P}_{\theta_{0}}\bigl{(}p(X)\leq u\bigr{)}=u for all u∈(0,1)u\in(0,1).