#### 18. Hypothesis Tests

*Question 1*

In this question, *n* = 20, H_{0}: *p* = 0.5 and H_{1}: *p* ≠ 0.5.

To be suspicious at the 5% level we want the P-value to be below 0.05. This would indicate there is some evidence to reject the null hypothesis (that the coin is fair). Since this is a two-sided question, we want the one-sided P-value P(*X* ≥ *x*) to be below 0.025.

Using the cumulative binomial distribution table (Table 11.4) for *n* = 20, we find *x* = 15 is the smallest value with a probability P(*X* ≥ *x*) below 0.025. Therefore 15 is the smallest number of heads (or tails) that would have to appear to be suspicious.

*Question 2*

Let μ be the mean difference in hops between the left and right legs. (We can't treat the left and right values separately since they are not independent.)

We want to test H_{0}: μ = 0 against H_{1}: μ ≠ 0.

From the *n* = 11 observed differences we find a mean of 1.00 hops with standard deviation 8.955 hops. The *t* statistic, with 10 degrees of freedom, is

*t*_{10} = (1.00 - 0)/(8.955/√11) = 0.37.

The P-value will obviously not be significant. (If you really to check, the critical value for 0.25 with 10 degrees of freedom is 0.700. Our statistic 0.37 is not even this big, so the one-sided P-value is at least 0.25, and so the two-sided P-value is at least 0.5.)

*Question 3*

Let μ be the mean hours of weekend sleep for all students.

We want to test H_{0}: μ = 16 against H_{1}: μ < 16.

From the *n* = 30 observations we find a mean of 16.18 hours with standard deviation 3.834. There is really no need to carry out a hypothesis test - since we are trying to show μ < 16 and we've actually observed 16.18 there will be no evidence. However, it is useful to see how the P-value comes out in this case.

The *t* statistic, with 29 degrees of freedom, is

*t*_{29} = (16.18 - 16)/(3.834/√30) = 0.26.

Since the alternative is μ < 16 the P-value is P(*T*_{29} < 0.26). You don't need a table to see that this is more than 0.5 (since the *t* distribution is symmetric about 0). Thus there is no evidence that the average hours of sleep is less than 16.