Lecture 31 Standard Tests Revisited

After two lectures on Bayesian inference we return to the tests of lectures 22 to 25. The most commonly used statistical tests, the zz-test, the tt-test, the chi-squared test for a variance and the FF-test, are often taught as recipes. In this lecture we consider these tests from the perspective of the module: each of them is based on a pivot in the sense of lecture 26.

31.1 Tests from Pivots

Every test in this lecture is based on the following principle: the distribution of the test statistic under the null hypothesis is known, and the test rejects if the statistic lies beyond a quantile of this distribution, taken from a table. In the language of lecture 26, the test statistic is a pivot Q⁢(X,θ)Q(X,\theta) evaluated at the hypothesised value θ=θ0\theta=\theta_{0}, and inverting the test as in lemma 26.6 gives the confidence interval based on this pivot.

We use the notation zpz_{p}, tk,pt_{k,p} and χk,p2\chi^{2}_{k,p} for the quantiles from lectures 22 and 26, so that ℙ⁢(T≤tk,p)=p\mathbb{P}(T\leq t_{k,p})=p for T∼tkT\sim t_{k}. Tables A.4, A.5 and A.6 in appendix A show these quantiles for a few values of pp. At level α\alpha, a one-sided test which rejects for large values of the statistic needs the (1−α)(1-\alpha)-quantile and a one-sided test which rejects for small values needs the α\alpha-quantile. A two-sided test needs the (1−α/2)(1-\alpha/2)-quantile and, if the distribution is not symmetric, also the (α/2)(\alpha/2)-quantile. A pp-value in the sense of definition 22.9 cannot be found exactly from such a table, but it can be bracketed between two tabulated levels, as in example 31.2 below.

The most basic example is the zz-test from lecture 22. In this lecture we write μ\mu instead of θ\theta for the mean of the normal distribution, since the variance will be a second parameter. If X1,…,Xn∼N⁢(μ,σ2)X_{1},\dots,X_{n}\sim N(\mu,\sigma^{2}) are i.i.d. with known σ2\sigma^{2}, then Z=n⁢(X¯−μ0)/σZ=\sqrt{n}\,(\bar{X}-\mu_{0})/\sigma is standard normally distributed under H0:μ=μ0H_{0}\colon\mu=\mu_{0}. In examples 22.7 and 22.8 we rejected H0H_{0} for Z>z1−αZ>z_{1-\alpha} or |Z|>z1−α/2|Z|>z_{1-\alpha/2}, for the one-sided and the two-sided alternative, respectively. The drawback of this test is that the variance of the data must be known. In the rest of the lecture the variance σ2\sigma^{2} is unknown.

31.2 The One-Sample tt-Test

Let X1,…,XnX_{1},\dots,X_{n} be i.i.d. N⁢(μ,σ2)N(\mu,\sigma^{2}), where both parameters are unknown, and let X¯\bar{X} and S2S^{2} be the sample mean and sample variance, respectively. If we replace σ\sigma in the definition of ZZ by the estimator SS, we get the test statistic

equation (31.1) (31.1)
T=n⁢(X¯−μ0)S.T=\frac{\sqrt{n}\,(\bar{X}-\mu_{0})}{S}.

In example 26.4 we have seen that for μ=μ0\mu=\mu_{0} the statistic TT is the ratio of the standard normal variable n⁢(X¯−μ0)/σ\sqrt{n}\,(\bar{X}-\mu_{0})/\sigma to the square root of S2/σ2S^{2}/\sigma^{2}. By proposition A.4, we have (n−1)⁢S2/σ2∼χn−12(n-1)S^{2}/\sigma^{2}\sim\chi^{2}_{n-1} and the numerator and denominator of the ratio are independent. Consequently, T∼tn−1T\sim t_{n-1} by definition A.5. This leads to the following tests.

Proposition 31.1.

Let n≥2n\geq 2 and let X1,…,XnX_{1},\dots,X_{n} be i.i.d. N⁢(μ,σ2)N(\mu,\sigma^{2}), where the parameters μ\mu and σ2\sigma^{2} are unknown. Let μ0∈ℝ\mu_{0}\in\mathbb{R} and let TT be given by (31.1). Then the three tests of H0:μ=μ0H_{0}\colon\mu=\mu_{0}, which reject if

T>tn−1,1−α,T<−tn−1,1−α,or|T|>tn−1,1−α/2,T>t_{n-1,1-\alpha},\qquad T<-t_{n-1,1-\alpha},\qquad\text{or}\qquad|T|>t_{n-1,% 1-\alpha/2},

for the alternatives μ>μ0\mu>\mu_{0}, μ<μ0\mu<\mu_{0} and μ≠μ0\mu\neq\mu_{0}, respectively, have size α\alpha, whatever the value of σ2\sigma^{2}.

Proof.

Under H0H_{0} we have T∼tn−1T\sim t_{n-1} for every value of σ2\sigma^{2}, as shown above. By the definition of the quantile we have ℙ⁢(T>tn−1,1−α)=1−(1−α)=α\mathbb{P}(T>t_{n-1,1-\alpha})=1-(1-\alpha)=\alpha. This is the size of the first test. The density of the tt distribution is symmetric about zero, and thus for the second test we have ℙ⁢(T<−tn−1,1−α)=ℙ⁢(T>tn−1,1−α)=α\mathbb{P}(T<-t_{n-1,1-\alpha})=\mathbb{P}(T>t_{n-1,1-\alpha})=\alpha. For the third test the same symmetry gives ℙ⁢(|T|>tn−1,1−α/2)=2⋅α/2=α\mathbb{P}(|T|>t_{n-1,1-\alpha/2})=2\cdot\alpha/2=\alpha. Since these probabilities do not depend on σ2\sigma^{2}, the probability of rejection under H0H_{0} is α\alpha for every value of σ2\sigma^{2}, and thus the size of each test is α\alpha. This completes the proof. ∎

These are the one-sided and two-sided one-sample tt-tests. Since tn−1,p>zpt_{n-1,p}>z_{p} for every p>1/2p>1/2, the tt-test requires a larger standardised deviation than the zz-test before it can reject the hypothesis. This is the price we pay for estimating σ\sigma, and it decreases as nn increases. As in lecture 22, the one-sided tests have level α\alpha for the composite null hypotheses μ≤μ0\mu\leq\mu_{0} and μ≥μ0\mu\geq\mu_{0}. We state this without proof.

By exercise 25.1, the generalised likelihood-ratio statistic for H0:μ=μ0H_{0}\colon\mu=\mu_{0} against the alternative μ≠μ0\mu\neq\mu_{0} is an increasing function of |T||T|. Thus the two-sided tt-test is the generalised likelihood-ratio test for this problem, with the exact tn−1t_{n-1} quantile in place of the χ12\chi^{2}_{1} approximation of Wilks’ theorem (theorem 25.3).

Example 31.2.

A quantity has nominal value 1010, and ten measurements give

10.2, 9.7, 11.1, 10.8, 10.4, 9.9, 11.3, 10.6, 10.1, 10.9.10.2,\ 9.7,\ 11.1,\ 10.8,\ 10.4,\ 9.9,\ 11.3,\ 10.6,\ 10.1,\ 10.9.

Assume that the measurements are i.i.d. N⁢(μ,σ2)N(\mu,\sigma^{2}). We want to test H0:μ=10H_{0}\colon\mu=10 against H1:μ≠10H_{1}\colon\mu\neq 10 at level α=0.05\alpha=0.05. The sum of the observations is 105105, so that x¯=10.5\bar{x}=10.5. The sum of the squared deviations from x¯\bar{x} is 2.522.52, so that s2=2.52/9=0.28s^{2}=2.52/9=0.28 and s=0.529s=0.529. The observed value of the test statistic is

t=10⁢(10.5−10)0.529=2.99.t=\frac{\sqrt{10}\,(10.5-10)}{0.529}=2.99.

The row for n−1=9n-1=9 degrees of freedom in table A.5 shows that we have t9,0.95=1.833t_{9,0.95}=1.833, t9,0.975=2.262t_{9,0.975}=2.262, t9,0.99=2.821t_{9,0.99}=2.821 and t9,0.995=3.250t_{9,0.995}=3.250. For a two-sided test with level 0.050.05 we need t9,0.975=2.262t_{9,0.975}=2.262 and since |t|=2.99>2.262|t|=2.99>2.262 we can reject H0H_{0}: the deviation of the measurements from the nominal value is significant at level 0.050.05. The same row also brackets the pp-value. The observed value 2.992.99 falls between t9,0.99t_{9,0.99} and t9,0.995t_{9,0.995} and thus the two-sided pp-value, 2⁢ℙ⁢(T≥2.99)2\,\mathbb{P}(T\geq 2.99) for T∼t9T\sim t_{9}, is between 0.010.01 and 0.020.02; the two-sided test also rejects at level 0.020.02 but not at level 0.010.01. If instead the question had been whether the measurements were high, the one-sided test for H0:μ=10H_{0}\colon\mu=10 against H1:μ>10H_{1}\colon\mu>10 at level 0.050.05 would have compared t=2.99t=2.99 to t9,0.95=1.833t_{9,0.95}=1.833 and would have rejected H0H_{0}, with a pp-value between 0.0050.005 and 0.010.01.

31.3 The Chi-Squared Test for a Variance

The second question about a normal sample concerns the spread of the data: we want to test whether the variance equals a given value σ02\sigma_{0}^{2}. By proposition A.4, the pivot (n−1)⁢S2/σ2(n-1)S^{2}/\sigma^{2} is χn−12\chi^{2}_{n-1} distributed whatever the value of the mean, and the test follows the structure of the test from the previous section.

Proposition 31.3.

Let n≥2n\geq 2 and let X1,…,XnX_{1},\dots,X_{n} be i.i.d. N⁢(μ,σ2)N(\mu,\sigma^{2}), where μ\mu and σ2\sigma^{2} are unknown. Let σ02>0\sigma_{0}^{2}>0 and let

equation (31.2) (31.2)
V=(n−1)⁢S2σ02.V=\frac{(n-1)S^{2}}{\sigma_{0}^{2}}.

Each of the three tests for H0:σ2=σ02H_{0}\colon\sigma^{2}=\sigma_{0}^{2}, which reject if

V>χn−1,1−α2,V<χn−1,α2,orV∉[χn−1,α/22,χn−1,1−α/22],V>\chi^{2}_{n-1,1-\alpha},\qquad V<\chi^{2}_{n-1,\alpha},\qquad\text{or}\qquad V% \notin\bigl{[}\chi^{2}_{n-1,\alpha/2},\ \chi^{2}_{n-1,1-\alpha/2}\bigr{]},

for the alternatives σ2>σ02\sigma^{2}>\sigma_{0}^{2}, σ2<σ02\sigma^{2}<\sigma_{0}^{2} and σ2≠σ02\sigma^{2}\neq\sigma_{0}^{2}, respectively, has size α\alpha, whatever the value of μ\mu.

Proof.

Under H0H_{0} we have V=(n−1)⁢S2/σ2∼χn−12V=(n-1)S^{2}/\sigma^{2}\sim\chi^{2}_{n-1} by proposition A.4, for every value of μ\mu. The first two rejection probabilities are 1−(1−α)=α1-(1-\alpha)=\alpha and α\alpha by the definition of the quantiles. For the third, the events V<χn−1,α/22V<\chi^{2}_{n-1,\alpha/2} and V>χn−1,1−α/22V>\chi^{2}_{n-1,1-\alpha/2} are disjoint and each of them has probability α/2\alpha/2, and thus the rejection probability is α\alpha. This completes the proof. ∎

Unlike the tt distribution, the chi-squared distribution is not symmetric, and thus a two-sided test needs a separate value from the table for each of the two tails. Inverting the two-sided test gives the confidence interval from example 26.5.

Example 31.4.

The output of a machine is specified to have variance σ02=4\sigma_{0}^{2}=4. After an adjustment of the machine, a sample of n=10n=10 i.i.d. N⁢(μ,σ2)N(\mu,\sigma^{2}) observations has sample variance s2=1.4s^{2}=1.4. We want to test H0:σ2=4H_{0}\colon\sigma^{2}=4 against H1:σ2<4H_{1}\colon\sigma^{2}<4 at level α=0.05\alpha=0.05. The observed value of the test statistic is v=9⋅1.4/4=3.15v=9\cdot 1.4/4=3.15, and the test rejects if v<χ9,0.052v<\chi^{2}_{9,0.05}. The row for 99 degrees of freedom in table A.6 shows that we have χ9,0.0252=2.700\chi^{2}_{9,0.025}=2.700. We also need the value χ9,0.052=3.325\chi^{2}_{9,0.05}=3.325, which is not tabulated. Since v=3.15<3.325v=3.15<3.325 we can reject H0H_{0}. The pp-value is ℙ⁢(W≤3.15)\mathbb{P}(W\leq 3.15) for W∼χ92W\sim\chi^{2}_{9}, and since 2.700<3.15<3.3252.700<3.15<3.325 this value is between 0.0250.025 and 0.050.05.

The same pivot gives the power function of the test. If the true variance is σ2\sigma^{2}, then W=(n−1)⁢S2/σ2∼χn−12W=(n-1)S^{2}/\sigma^{2}\sim\chi^{2}_{n-1} and V=W⁢σ2/σ02V=W\sigma^{2}/\sigma_{0}^{2}, and thus we find

β⁢(σ2)=ℙσ2⁢(V<χn−1,α2)=ℙ⁢(W<χn−1,α2⁢σ02/σ2).\beta(\sigma^{2})=\mathbb{P}_{\sigma^{2}}\bigl{(}V<\chi^{2}_{n-1,\alpha}\bigr{% )}=\mathbb{P}\bigl{(}W<\chi^{2}_{n-1,\alpha}\,\sigma_{0}^{2}/\sigma^{2}\bigr{)}.

This probability decreases as σ2\sigma^{2} increases. Thus, over the composite null hypothesis σ2≥σ02\sigma^{2}\geq\sigma_{0}^{2} the power function is largest at σ02\sigma_{0}^{2}, and the test has size α\alpha for this null hypothesis as well. Exercise 31.2 treats the test against σ2>σ02\sigma^{2}>\sigma_{0}^{2} in the same way.

31.4 Paired and Two-Sample Problems

The tests so far have considered a single sample. We now consider three more standard tests for two sets of measurements. Each of these tests is again based on a pivot.

The first of these three tests is the paired tt-test. Assume that we have observed data in pairs (Xi,Yi)(X_{i},Y_{i}), i=1,…,ni=1,\dots,n, e.g. before and after measurements for the same subject. The two measurements for one subject are in general not independent, and thus the data cannot be treated as two independent samples. Instead, we reduce the data for each pair to the difference Di=Xi−YiD_{i}=X_{i}-Y_{i}, model the differences as i.i.d. N⁢(μD,σD2)N(\mu_{D},\sigma_{D}^{2}) and apply proposition 31.1 with μ0=0\mu_{0}=0: the test statistic T=n⁢D¯/SDT=\sqrt{n}\,\bar{D}/S_{D}, constructed from the sample mean and variance of the differences, is tn−1t_{n-1} distributed under H0:μD=0H_{0}\colon\mu_{D}=0. The model only makes assumptions about the differences (exercise 31.3).

The second test is the two-sample tt-test. Here we assume that X1,…,XmX_{1},\dots,X_{m} are i.i.d. N⁢(μX,σ2)N(\mu_{X},\sigma^{2}) and that Y1,…,YnY_{1},\dots,Y_{n} are i.i.d. N⁢(μY,σ2)N(\mu_{Y},\sigma^{2}), where the two samples are independent of each other and have the same unknown variance σ2\sigma^{2}. We consider H0:μX=μYH_{0}\colon\mu_{X}=\mu_{Y}. If SX2S_{X}^{2} and SY2S_{Y}^{2} are the sample variances of the two samples, the pooled estimator for the common variance is

Sp2=(m−1)⁢SX2+(n−1)⁢SY2m+n−2,S_{p}^{2}=\frac{(m-1)S_{X}^{2}+(n-1)S_{Y}^{2}}{m+n-2},

and the test statistic is

equation (31.3) (31.3)
T=X¯−Y¯Sp⁢1/m+1/n∼tm+n−2under ⁢H0.T=\frac{\bar{X}-\bar{Y}}{S_{p}\sqrt{1/m+1/n}}\sim t_{m+n-2}\qquad\text{under }% H_{0}.

The distribution follows as in the one-sample case. Proposition A.4, applied to each of the two samples, shows that (m+n−2)⁢Sp2/σ2(m+n-2)S_{p}^{2}/\sigma^{2} is the sum of two independent chi-squared variables with m−1m-1 and n−1n-1 degrees of freedom, and that this sum is independent of X¯−Y¯\bar{X}-\bar{Y}. By definition A.2, the sum is χm+n−22\chi^{2}_{m+n-2} distributed. The test of H0H_{0} against μX≠μY\mu_{X}\neq\mu_{Y} rejects if |T|>tm+n−2,1−α/2|T|>t_{m+n-2,1-\alpha/2}, and the one-sided variants of the test use tm+n−2,1−αt_{m+n-2,1-\alpha}.

The third test is the FF-test for two variances. In the same two-sample setting, but now with variances σX2\sigma_{X}^{2} and σY2\sigma_{Y}^{2} which are allowed to be different, the ratio (SX2/σX2)/(SY2/σY2)(S_{X}^{2}/\sigma_{X}^{2})\big{/}(S_{Y}^{2}/\sigma_{Y}^{2}) is Fm−1,n−1F_{m-1,n-1} distributed by proposition A.4 and definition A.5. Under H0:σX2=σY2H_{0}\colon\sigma_{X}^{2}=\sigma_{Y}^{2} the unknown variances cancel and the statistic F=SX2/SY2F=S_{X}^{2}/S_{Y}^{2} is Fm−1,n−1F_{m-1,n-1} distributed. The two-sided test rejects if FF does not fall into the interval [Fm−1,n−1,α/2,Fm−1,n−1,1−α/2][F_{m-1,n-1,\alpha/2},\,F_{m-1,n-1,1-\alpha/2}], where Fk,l,pF_{k,l,p} is the pp-quantile of Fk,lF_{k,l}.

31.5 Which Test?

Table 31.1 summarises the six tests. The choice between them is determined by the following three questions: Is the parameter in question a mean or a variance? Is there one sample or two? If two samples, are the observations paired or independent? All six tests assume that the data are normally distributed.

Question H0H_{0} Statistic Null distribution
one mean, σ2\sigma^{2} known μ=μ0\mu=\mu_{0} n⁢(X¯−μ0)/σ\sqrt{n}\,(\bar{X}-\mu_{0})/\sigma N⁢(0,1)N(0,1)
one mean, σ2\sigma^{2} unknown μ=μ0\mu=\mu_{0} n⁢(X¯−μ0)/S\sqrt{n}\,(\bar{X}-\mu_{0})/S tn−1t_{n-1}
paired differences μD=0\mu_{D}=0 n⁢D¯/SD\sqrt{n}\,\bar{D}/S_{D} tn−1t_{n-1}
one variance, μ\mu unknown σ2=σ02\sigma^{2}=\sigma_{0}^{2} (n−1)⁢S2/σ02(n-1)S^{2}/\sigma_{0}^{2} χn−12\chi^{2}_{n-1}
two means, common σ2\sigma^{2} μX=μY\mu_{X}=\mu_{Y} X¯−Y¯Sp⁢1/m+1/n\frac{\bar{X}-\bar{Y}}{S_{p}\sqrt{1/m+1/n}} tm+n−2t_{m+n-2}
two variances σX2=σY2\sigma_{X}^{2}=\sigma_{Y}^{2} SX2/SY2S_{X}^{2}/S_{Y}^{2} Fm−1,n−1F_{m-1,n-1}
Table 31.1: The standard tests for normal data. Each statistic is the pivot evaluated at the null value, and the final column gives the distribution of the statistic under H0H_{0}. The critical values are quantiles of this distribution, as described in section 31.1.
Summary.
  • •
    ​

    Each of the standard tests for normal data is based on a pivot from lecture 26, evaluated at the null value and compared to a quantile of the known null distribution. Inverting the test gives the corresponding confidence interval.

  • •
    ​

    The one-sample tt-test uses T=n⁢(X¯−μ0)/S∼tn−1T=\sqrt{n}\,(\bar{X}-\mu_{0})/S\sim t_{n-1} under H0:μ=μ0H_{0}\colon\mu=\mu_{0} and rejects for T>tn−1,1−αT>t_{n-1,1-\alpha} (one-sided) or |T|>tn−1,1−α/2|T|>t_{n-1,1-\alpha/2} (two-sided). The two-sided test is the generalised likelihood-ratio test with an exact critical value.

  • •
    ​

    The chi-squared test for a variance uses V=(n−1)⁢S2/σ02∼χn−12V=(n-1)S^{2}/\sigma_{0}^{2}\sim\chi^{2}_{n-1} under H0:σ2=σ02H_{0}\colon\sigma^{2}=\sigma_{0}^{2}. A two-sided test requires both lower and upper quantiles, since the distribution is not symmetric.

  • •
    ​

    The paired tt-test is a one-sample tt-test for the differences. Similarly, the two-sample tt-test with pooled variance and the FF-test for two variances follow this pattern, using the tm+n−2t_{m+n-2} and Fm−1,n−1F_{m-1,n-1} distributions.

  • •
    ​

    The table lists only a few quantiles and often the pp-value is bracketed between two tabulated levels.

Exercise 31.1.

Eight independent measurements of a quantity with nominal value 2020 are given by

19.1, 18.6, 20.3, 19.4, 18.9, 19.8, 18.2, 19.7.19.1,\ 18.6,\ 20.3,\ 19.4,\ 18.9,\ 19.8,\ 18.2,\ 19.7.

Assume that the measurements are i.i.d. N⁢(μ,σ2)N(\mu,\sigma^{2}), where both parameters are unknown. From table A.5 we find t7,0.95=1.895t_{7,0.95}=1.895, t7,0.975=2.365t_{7,0.975}=2.365, t7,0.99=2.998t_{7,0.99}=2.998 and t7,0.995=3.499t_{7,0.995}=3.499.

  1. 1.
    ​

    Determine x¯\bar{x}, s2s^{2} and the observed value of the test statistic TT from (31.1) for μ0=20\mu_{0}=20.

  2. 2.
    ​

    For H0:μ=20H_{0}\colon\mu=20, test H1:μ<20H_{1}\colon\mu<20 at levels 0.050.05 and 0.010.01. Bracket the pp-value.

  3. 3.
    ​

    For H0:μ=20H_{0}\colon\mu=20, test H1:μ≠20H_{1}\colon\mu\neq 20 at the same two levels and bracket the pp-value.

  4. 4.
    ​

    Calculate the 99%99\% tt-interval for μ\mu from example 26.4 and discuss how it relates to your answer in the previous part.

Exercise 31.2.

A sample of n=15n=15 i.i.d. N⁢(μ,σ2)N(\mu,\sigma^{2}) observations has sample variance s2=2.7s^{2}=2.7, and the process generating the sample is specified to have variance at most 1.51.5. From table A.6 we find χ14,0.0252=5.629\chi^{2}_{14,0.025}=5.629, χ14,0.952=23.685\chi^{2}_{14,0.95}=23.685, χ14,0.9752=26.119\chi^{2}_{14,0.975}=26.119 and χ14,0.992=29.141\chi^{2}_{14,0.99}=29.141.

  1. 1.
    ​

    Test H0:σ2≤1.5H_{0}\colon\sigma^{2}\leq 1.5 against H1:σ2>1.5H_{1}\colon\sigma^{2}>1.5 at levels 0.050.05 and 0.010.01. Bracket the pp-value.

  2. 2.
    ​

    Test H0:σ2=1.5H_{0}\colon\sigma^{2}=1.5 against H1:σ2≠1.5H_{1}\colon\sigma^{2}\neq 1.5 at level 0.050.05.

  3. 3.
    ​

    Show that the power function of the one-sided test from proposition 31.3 is given by β⁢(σ2)=ℙ⁢(W>χn−1,1−α2⁢σ02/σ2)\beta(\sigma^{2})=\mathbb{P}\bigl{(}W>\chi^{2}_{n-1,1-\alpha}\,\sigma_{0}^{2}/% \sigma^{2}\bigr{)} where W∼χn−12W\sim\chi^{2}_{n-1}, and that this power function is increasing in σ2\sigma^{2}. Deduce that the test has size α\alpha for the composite null hypothesis σ2≤σ02\sigma^{2}\leq\sigma_{0}^{2}.

  4. 4.
    ​

    Explain why the one-sided test from the first part and the two-sided test from the second part give different results at level 0.050.05. Which of the two tests has the larger power against alternatives σ2>σ02\sigma^{2}>\sigma_{0}^{2}?

Exercise 31.3.

The following data give the reaction times of six subjects before and after a training period.

subject 1 2 3 4 5 6
before (xix_{i}) 72 65 80 58 69 75
after (yiy_{i}) 68 66 74 55 63 70

We want to know whether the training reduced the mean reaction time. From table A.5 we find t5,0.95=2.015t_{5,0.95}=2.015, t5,0.975=2.571t_{5,0.975}=2.571, t5,0.99=3.365t_{5,0.99}=3.365 and t10,0.95=1.812t_{10,0.95}=1.812.

  1. 1.
    ​

    Write down the model and hypotheses for the paired tt-test and carry out the test at levels 0.050.05 and 0.010.01.

  2. 2.
    ​

    Determine a 95%95\% confidence interval for the mean reduction in reaction time.

  3. 3.
    ​

    A colleague, not knowing that the two rows of the table give paired data, performs the two-sample tt-test (31.3). The sample variances of the two rows are sX2=59.77s_{X}^{2}=59.77 and sY2=42.80s_{Y}^{2}=42.80, respectively. What is the test statistic and what is the decision of your colleague at level 0.050.05? Explain why the paired analysis is the appropriate one and why the two analyses give different results.

Exercise 31.4.

In example 26.4 we have observed a sample of n=16n=16 values, where x¯=10.3\bar{x}=10.3 and s=2.1s=2.1, and we have found the 95%95\% tt-interval [9.18,11.42][9.18,11.42] for μ\mu. In example 26.5, for the same data, we have found the 95%95\% interval [2.41,10.56][2.41,10.56] for σ2\sigma^{2}. In exercise 26.4 we have seen that the hypothesis H0:μ=9H_{0}\colon\mu=9 was rejected at level 0.050.05, using lemma 26.6 alone. Now use the values t15,0.95=1.753t_{15,0.95}=1.753, t15,0.975=2.131t_{15,0.975}=2.131, χ15,0.0252=6.262\chi^{2}_{15,0.025}=6.262 and χ15,0.9752=27.488\chi^{2}_{15,0.975}=27.488.

  1. 1.
    ​

    Perform a two-sided tt-test for H0:μ=9H_{0}\colon\mu=9 and state the decision. Repeat the test for H0:μ=11.5H_{0}\colon\mu=11.5 and check that the result is consistent with the interval.

  2. 2.
    ​

    For H0:σ2=σ02H_{0}\colon\sigma^{2}=\sigma_{0}^{2}, perform a two-sided test at level 0.050.05 for σ02=2\sigma_{0}^{2}=2 and σ02=9\sigma_{0}^{2}=9, either from the interval alone or by computing the test statistic (31.2).

  3. 3.
    ​

    Perform a one-sided test for H0:μ=9.5H_{0}\colon\mu=9.5 against H1:μ>9.5H_{1}\colon\mu>9.5 at level 0.050.05. Why can the two-sided interval not be used for this test? Which confidence set corresponds to this test?