Homework Exercises 1. You want to conduct a test of significance for p the population proportion. The test you will run is H 0 : p = 0.4 Ha: p > 0.4, n = 80. you decide that the critical value will be ˆp c = 0.51. What is the probability of a type I error? Since we will reject the null hypothesis when ˆp c > 0.51, then we need to calculate how likely is it to get such a p-hat value if p = 0.4, for a sample size of 80. P(type I error) = the chance of rejecting the null hypothesis, when the null hypothesis is correct. Now that I know what I want to calculate the question is HOW WILL I CALCULATE IT? I notice that 0.4(80) = 32 which means that when I sample I would expect 32 successes; also (1 0.4)(80) = 48, which means that when I sample 80 values, I expect 48 will result in failure. The criteria mentioned in page 541 of your text, outlines the procedure if we have at least 10 success and 10 failures. We have met this criteria, so now we have an option on HOW to calculate the said probability. The method will be to assume the distribution of ˆp c is fairly normal, enough so that I can p(1 o p) o σ use p as the value for µ and for n n. P( ˆp c > 0.51) PZ > 0.51 0.4 0.4(0.6) 80 P(Z > 2.01) 2.22%. 0.0222 The probability of incorrectly rejecting the null hypothesis (type I error) is about Again I want to emphasize this is just an approximation. What we are teaching you is a method that yields an approximation, which is what is done in many studies. What is the correct number? Using up to four decimal places, the actual probability of a type I error for the situation described is 0.02712. The criteria of at least 10 successes and at least 10 failures allows us to understand that while our result is not correct, we are not far off from the correct value.
2. An airline s public relations department says that the airline rarely loses passengers luggage. It further claims that on those occasions when luggage is lost, 90% is recovered and delivered to its owner within 24 hours. A consumer group wants to sample 122 air travelers from this company who lost their luggage. The consumer group will run the following test: H 0 : p = 0.9 Ha: p < 0.9, n = 122. Suppose that the significance level is 5%, and let us say that the effect size is 0.05, that is, a change of 5% would be deemed important by the consumer group enough to warrant action. This means the alternative hypothesis is 0.85. a) Calculate the power of the test of hypothesis (significance test) for this possible alternative value of p. Before I start, I will see if I can use a normal approximation as was done in problem 1 to calculate my probabilities. Assuming p = 0.9 is correct then on a sample of 122, I would expect 122(0.9) = 109.8 successes, and 122(1 0.9) = 12.2 failures. Thus, I meet the criteria of at least 10 successes and 10 failures, so I will assume that a normal calculation will yield values that are close to the actual values. Distribution of p-hat when p = 0.9 Probablility 0.15 0.1 0.05 0 0.7 0.75 0.8 0.85 0.9 0.95 1 Possible p-hat values when n = 122 Only values above 0.72 were listed Next I need to convert the significance level to its corresponding critical value, ˆp c. Looking at a chart, like the one in the back of your book or using software, I find that a tail of 5% corresponds to a z-score of 1.645 for a normal curve (the proposed distribution of ˆp ) ˆpc 0.9-1.645 = 0.9(0.1) 122 When I solve I get ˆp c = 0.8553 To calculate power the question becomes, if p a = 0.85 how likely are we to get a value as low or lower than 0.8553(direction determined by the direction of the alternative)?
Distribution of p-hat when p = 0.85 and n = 122 Probabilities 0.12 0.1 0.08 0.06 0.04 0.02 0 0.7 0.75 0.8 0.85 0.9 0.95 1 Possible p-hat values, when p = 0.85 0.8553 0.85 P( ˆp c < 0.8553) PZ < 0.85(0.15) 122 P(Z < 0.164) 0.5651 I used a computer to calculate this value (on Excel the command is = normsdist(0.164) ) The actual power value good to four decimal places is 0.5690. b) What is the probability of a type II error. P(type II error) = 1 0.5651
3. You wish to run a significance test (test of hypothesis) H 0 : p = 0.2 Ha: p > 0.2, n = 20 Because the criteria np > 10 and n(1 p) > 10 is no longer met, then I can no longer use a normal approximation method used previously. Below is the table of possible ˆp values that can be attained from a sample of 20 along with the probability of each (the symbol 1E-08 means 1 x 10-8 ). Successes ouf of 20 0 1 2 3 4 5 6 7 8 9 ˆp 0 0.05 0.1 0.15 0.2 0.25 0.3 0.35 0.4 0.45 Probability, P( ˆp = k) 0.0115 0.0576 0.1369 0.2054 0.2182 0.1746 0.1091 0.0545 0.0222 0.0074 Successes ouf of 20 10 11 12 13 14 15 16 17 18 19 20 ˆp 0.5 0.55 0.6 0.65 0.7 0.75 0.8 0.85 0.9 0.95 1 Probability, P( ˆp = k) 0.002 0.0005 9E-05 1E-05 2E-06 2E-07 1E-08 8E-10 3E-11 8E-13 1E-14 a) I decide to consider that there is enough evidence against the null if my sample proportion, ˆp, is greater than or equal to 0.4 (8 successes out of 20 attempts). What is the probability of a type I error. Again, I note the direction of the alternative hypothesis; Ha: p > 0.2. This confirms the direction that will result in the rejection of the null, as stated in the question. Thus P(type I error) = P( ˆp c > 0.4) which I can get by adding up all the corresponding probabilities below. P( ˆp c > 0.4) = 0.0222 + 0.0074 + 0.002 + 0.0005+ 0.000000005 (note I put fifth term down to emphasize that while many values remain, they do not add much to the final value, so I will not consider the fifth term and beyond). P(type I error) = 0.0321 b) Suppose that in reality the value of the population proportion, p is 0.35, alternative hypothesized value. Then the table above is not reality, and reality is the table featured below. Keep in mind that you will still run the test given originally, meaning you will reject the null hypothesis if ˆp, is greater than or equal to 0.4 (8 successes out of 20 attempts). What is the power of the hypothesis test you will run, with respect to alternative proportion? Successes ouf of 20 0 1 2 3 4 5 6 7 8 9 ˆp 0 0.05 0.1 0.15 0.2 0.25 0.3 0.35 0.4 0.45 Probability, P( ˆp = k) 0.0002 0.002 0.01 0.0323 0.0738 0.1272 0.1712 0.1844 0.1614 0.1158 Successes ouf of 20 10 11 12 13 14 15 16 17 18 19 20 ˆp 0.5 0.55 0.6 0.65 0.7 0.75 0.8 0.85 0.9 0.95 1 Probability, P( ˆp = k) 0.0686 0.0336 0.0136 0.0045 0.0012 0.0003 4E-05 6E-06 5E-07 3E-08 8E-10 power = P( ˆp c > 0.4) = 0.1614 + 0.1158 + 0.0686 + 0.0336 + 0.0136 + 0.0045 + 0.0012 + 0.0003 = 0.3990
4. Is there such a thing as home field advante in football? In order to provide evidence that field advantage is real, a group will sample NFL games from 1990 to 2005. The assumption will be that there is no such thing as field advantage. This then will mean that half the time the home team will win and half the time the home team will lose. The proportion p, will represent the proportion of times the home team wins. The significance test run will be H 0 : p = 0.5 Ha: p > 0.5, n = 100, a) We will reject the null hypothesis if ˆp > 0.65. What is the probability of a type I error? What is the value 0.65 called? The value 0.65 is the critical value, ˆp c. Next I need to check to see if I meet the criteria for a normal approximation, which I do because I am expecting 50 successes and 50 failures. 0.65 0.5 P( ˆp > 0.65) PZ > 0.5(0.5) Distribution of p-hat when p =0.5 and n =100 100 0.1 P(Z > 3) 0.08 0.06 0.0013 There is a Probability 0.04 0.02 0 0.3 0.35 0.4 0.45 0.5 0.55 0.6 0.65 0.7 p-hat b) Suppose that an effect size of 0.15 is deemed to be important. What is the probability of a type II error? The type II error occurs when we fail to reject the null hypothesis when in fact it is not correct. So, suppose that p a = 0.65. It also happens to be the critical value. If I am assuming a normal distribution then, P(type II error) P( ˆp < 0.65) = 0.5 c) What is the power of this test? P(power) = 1 P(type II error) = 0.5
5. Below are two discreet distributions for the random variable X, the number of freethrows my friend can make out of 10 attempts (Assumption on the use of normal calculations not appropriate for this scenario; does not meet np> 10 and n(1 p) > 10. I will assume that my friends ability is modeled by the following distribution. Null hypothesis view Number of freethrows made, X 0 1 2 3 4 5 6 7 8 9 10 probability of making X freethrows 0.0010 0.0098 0.0439 0.1172 0.2051 0.2461 0.2051 0.1172 0.0439 0.0098 0.0010 The alternative view is given by Alternative hypothesis view Number of freethrows made, X 0 1 2 3 4 5 6 7 8 9 10 probability of making X freethrows 0.107 0.268 0.302 0.201 0.088 0.026 0.006 8E-04 7E-05 4E-06 1E-07 Note the notation 8E-04 is equivalent to 8 x 10-4. If the number of freethrows made is 2 or less I will assume that the null hypothesis view is not correct, and choose the alternative view. a) What is the probability of a type I error? P(type I error) = 0.0010 + 0.0098 + 0.0439 = 0.0547 b) What is the probability of a type II error? P(type II error) = P(X 3) = 0.201 + 0.088 + 0.026 + 0.006 = 0.3219 c) What is the power? P(power) = P(X 2) = 0.107 + 0.268 +.302 =.677