## MS Mod 4: Hypotheses and Test Procedures – practice problems

 Author Message NEAS Supreme Being         Group: Administrators Posts: 4.3K, Visits: 1.3K MS Module 4: Hypotheses and Test Procedures – practice problems(The attached PDF file has better formatting.)Exercise 4.1: Type I and Type II errorsLet α = the probability of a Type I error, and let β = the probability of a Type II error.A gambler fears that a coin is biased and is more likely to be Heads than Tails. Let p = the probability that the coin shows up as Heads when it is flipped.●    The null hypothesis is p ≤ 50%.●    The alternative hypothesis is p > 50%.The coin is flipped N = 10 times. The test statistic (X) is the number of Heads in the N coin flips. The null hypothesis is rejected if the number of Heads is more than N–2.A.    What is α, the probability of a Type I error?B.    What is β, the probability of a Type II error, if the true probability of Heads is 60%?Part A: α = P(0.5, N, N-1) + P(0.5, N, N)= n × ½n-1 × ½ + ½n= 11 / 1,024 = 0.010742188Part B: We use the 60% probability of Heads for the probability of a Type II error: β = 1 – P(0.6, N, N-1) – P(0.6, N, N)= 1 – n × 0.6n-1 × 0.4 – 0.6n = 1 – 10 × 0.69 × 0.4 – 0.610 = 0.95364 Exercise 4.2: Type I and Type II errorsLet α = the probability of a Type I error, and let β = the probability of a Type II error.A gambler uses a biased coin that has a 60% chance of showing Heads when it is flipped. The gambler fears that someone has replaced the biased coin with a fair coin that has a 50% chance of showing Heads when it is flipped. Let p = the probability that the coin is Heads when it is flipped.●    The null hypothesis is p = 60%.●    The alternative hypothesis is p = 50%.The coin is flipped N = 10 times. The test statistic (X) is the number of Heads in the N coin flips. The null hypothesis is rejected if the number of Heads is less than 3.A.    What is α, the probability of a Type I error?B.    What is β, the probability of a Type II error, if the true probability of Heads is 50%?Part A: α = P(0.6, N, 0) + P(0.6, N, 1) + P(0.6, N, 2)= 0.4n + n × 0.4n-1 × 0.6 + ½ × n × (n-1) × 0.4n-2 × 0.62= 0.410 + 10 × 0.4(10 – 1) × 0.6 + ½ × 10 × (10 – 1) × 0.4(10 – 2) × 0.62 = 0.01229Part B: We use the 50% probability of Heads for the probability of a Type II error:β = 1 – (P(0.5, N, 0) + P(0.5, N, 1) + P(0.5, N, 2) )= 1 – 0.5n – n × 0.5n-1 × 0.5 – ½ × n × (n-1) × 0.5n-2 × 0.52= 1 – 0.510 – 10 × 0.5(10 – 1) × 0.5 – ½ × 10 × (10 – 1) × 0.5(10 – 2) × 0.52 = 0.94531 Exercise 4.3: Probabilities of Type I and Type II errorsA population has a normal distribution with a mean μ0 of 80 and a standard deviation of 8.One group from this population has been treated to reduce its mean; we assume it is still normally distributed with the same standard deviation. A sample of size 36 from this treated group has a sample mean of and a true mean of μʹ.●    The null hypothesis is H0: μʹ = μ0.●    The one-sided alternative hypothesis is Ha: μʹ < μ0.We reject the null hypothesis if ≤ 78.A.    What is the standard deviation of the sample mean?B.    What is the z statistic value to test the null hypothesis?C.    What is the probability of a Type I error for this one-sided (lower-tailed) test?D.    If the true mean of the sample is 76, what is the probability of a Type II error for this test?Part A: The standard deviation of the sample mean is 8 / 360.5 = 1.33333Part B: The z value is (78 – 80) / 1.333333 = -1.500000Part C: The probability of a Type I error for the one-sided (lower-tailed) test is Φ(–1.5) = 0.0668.Part E: The probability of a Type II error for the one-sided (lower-tailed) test is 1 – Φ( ( – μʹ) / σ) = 1 – Φ ( (78 – 76) / 1.33333) = 1 – Φ(1.5) = 1 – 0.93319 = 0.06681.Question: This exercise doesn’t give a significance level such as 5% or 1%.Answer: This exercise gives a rejection region of ≤ 78. The implied significance level α is 6.681%. We can derive the significance level from the rejection region or the rejection region from the significance level. Given the rejection region, we derive the probability of a Type II error (β) for each true value of μʹ (the true value of the tested sample). The β value can also be expressed in terms of the significance level α, which is the formula used in most examples. Exercise 4.4: Type 1 and Type 2 errorsLet μ be the unknown mean of a normal distribution with σ = 1,500. ●    The null hypothesis is H0: μ = 30,000●    The alternative hypothesis is Ha: μ > 30,000A statistician tests the null hypothesis with α (the probability of a Type I error) = 1% and a sample of size 16.A.    What is the probability of making a type II error if μ = 31,000?B.    If β (the probability of a type II error when μ = 31,000) is to be no more than 10%, how many observations N are needed?Part A: A test with α = 0.01 requires za = z.01 = 2.33. The probability of making a type II error if μ = μʹ isΦ(zα + (μ0 – μʹ) / (σ/√n) ) so β(31,000) = Φ(2.33 + (30,000 – 31,000) / (1500 / √16) ) = Φ(–0.34) = 0.3669so β(31,000) = Φ(2.32635 + (30,000 – 31,000) / (1500 / √16) ) = Φ(–0.3403) = 0.36682.32635 + (30,000 – 31,000) / (1500 / 160.5 ) = -0.3403(Excel: =NORM.DIST(-0.34,0,1,1) )(Excel: =NORM.DIST(-0.3403,0,1,1) )Part B: the needed sample size isn = (σ × (zα + zβ) / (μ0 – μʹ) )2If β(31,000) = 0.1, so z0.1 = 1.28, the needed sample size is n = ( 1,500 × (2.33 + 1.28) / (30,000 – 31,000) )2 = (–0.542)2 = 29.32.n = ( 1,500 × (2.32635 + 1.28155) / (30,000 – 31,000) )2 = 29.29 Exercise 4.5: Type 1 and Type 2 errors, one-tailed testLet μ be the unknown mean of a normal distribution with σ = 18. ●    The null hypothesis is H0: μ = 100●    The alternative hypothesis is Ha: μ > 100A statistician tests the null hypothesis with α (the probability of a Type I error) = 1% and a sample of size 36.A.    What is the probability of making a type II error if μ = 110, or β(110)?B.    If β(110) is to be no more than 10%, how many observations N are needed?Part A: A test with α = 0.01 requires zα = z.01 = 2.32635. The probability of making a type II error if μ = μʹ isΦ(zα + (μ0 – μʹ) / (σ/√n) ) We compute: 2.32635 + (100 – 110) / (18 / 360.5 ) = -1.006983so β(110) = Φ(2.32635 + (100 – 110) / (18 / √36) ) = Φ(-1.006983) = 0.15697For the final exam, you look up the values of the cumulative standard normal distribution in tables provided. For the practice problems, values of the cumulative standard normal distribution are given by the Excel built-in function NORM.S.DIST, and values for other normal distributions are given by the function NORM.DIST.Part B: the needed sample size is n = (σ × (zα + zβ) / (μ0 – μʹ) )2If β(110) = 0.1, z0.1 = 1.28155, and the needed sample size is     n = ( 18 × (2.32635 + 1.28155) / (100 – 110) )2 = 42.17The number of observations is an integer. For β(110) to be no more than 10%, we round up to 43. Exercise 4.6: Type 1 and Type 2 errors, two-tailed testLet μ be the unknown mean of a normal distribution with σ = 18. ●    The null hypothesis is H0: μ = 100●    The alternative hypothesis is Ha: μ ≠ 100A statistician tests the null hypothesis with α (the probability of a Type I error) = 1% and a sample of size 36.A.    What is the probability of making a type II error if μ = 110?B.    If β(110), the probability of a type II error when μ = 110, is to be no more than 10%, how many observations N are needed?Part A: A test with α = 0.01 requires zα/2 = z.005 = 2.57583. The probability of making a type II error if μ = μʹ isΦ(zα/2 + (μ0 – μʹ) / (σ/√n) ) – Φ( –zα/2 + (μ0 – μʹ) / (σ/√n) ) The formula for the two-sided test replaces zα by zα/2; for z = 0.01, zα = 2,326348, and zα/2 = 2.575829.We compute: ●    2.57583 + (100 – 110) / (18 / 360.5 ) = -0.75750    ○    Φ (-0.75750) = 0.224375●    –2.57583 + (100 – 110) / (18 / 360.5 ) = -5.90916    ○    Φ (-5.90916) = 1.7193E-09 (≈ 0).so β(110) = Φ(-0.75750) – Φ(-5.90916) = 0.224375For the final exam, you look up the values of the cumulative standard normal distribution in tables provided. For the practice problems, values of the cumulative standard normal distribution are given by the Excel built-in function NORM.S.DIST, and values for other normal distributions are given by the function NORM.DIST.Part B: The needed sample size for a two-tailed test is n = (σ × (zα/2 + zβ) / (μ0 – μʹ) )2If β(110) = 0.1, z0.1 = 1.28155, and the needed sample size is     n = ( 18 × (2.57583 + 1.28155) / (100 – 110) )2 = 48.21 Exercise 4.7: T test, one sampleA sample of N=15 observations from a normal distribution has ●    xi = 120 (sum of the N observations)●    xi2 = 3,600 (sum of the squares of the N observations)●    The null hypothesis is H0: the population mean μ0 = 4●    This exercise shows the procedure for one-tailed and two-tailed tests, with either    ○    The two-tailed alternative hypothesis is Ha: the population mean μ0 ≠ 4    ○    The one-tailed (upper tailed) alternative hypothesis is Ha: the population mean μ0 > 4A.    What is the sample mean of the N observations?B.    What is the sample standard deviation of the N observations?C.    What is the t value used to test the null hypothesis?D.    What is the p value for the one-tailed alternative hypothesis?E.    What is the p value for the two-tailed alternative hypothesis?Part A: The sample mean is xi / N = 120 / 15 = 8.Part B: The sample standard deviation = { [ xi2 – (xi)/N ] / (N – 1) }0.5 =    ( (3,600 – 1202 / 15) / (15 – 1) )0.5 = 13.732131Part C: The t value used to test the null hypothesis is ( – μ0) / (σ / N0.5) =    (8 – 4) / (13.732131 /150.5) = 1.128152Part D: The p value for the one-tailed alternative hypothesis = 0.1391 (table look-up or spreadsheet function)Part E: The p value for the two-tailed alternative hypothesis = 0.2782 (table look-up or spreadsheet function) Attachments MS Module 4 HypothesesTest Procedures – practice problems df.pdf (486 views, 78.00 KB) Edited 4 Years Ago by NEAS tud55886 t Junior Member         Group: Forum Members Posts: 11, Visits: 151 There is a mistake in exercise 4.1 part B: i‌t should be β = 1-(P(0.6, N, N-1) + P(0.6, N, N)), the calculation is correct but the formula is wrong. tud55886 t Junior Member         Group: Forum Members Posts: 11, Visits: 151 There is an error in 4.2 part B:i‌t should be Part B: β = 1-(P(0.6, N, 0) + P(0.6, N, 1) + P(0.6,N,2)), also the calculation is wrong. tud55886 t Junior Member         Group: Forum Members Posts: 11, Visits: 151 What distribution should we use for exercise 4.7 part D and E? The result I'm getting using the Normal distribution is Part D: 0.1292 and part E: 0.2584 NEAS Supreme Being         Group: Administrators Posts: 4.3K, Visits: 1.3K +x tud55886 - 10/3/2019 7:23:42 PMWhat distribution should we use for exercise 4.7 part D and E? The result I'm getting using the Normal distribution is Part D: 0.1292 and part E: 0.2584[NEAS: Yes, a normal distribution.] MyriamSakr M Forum Newbie         Group: Forum Members Posts: 2, Visits: 60 +x tud55886 - 10/3/2019 6:09:46 PMThere is an error in 4.2 part B:i‌t should be Part B: β = 1-(P(0.6, N, 0) + P(0.6, N, 1) + P(0.6,N,2)), also the calculation is wrong.Also we should use p=.5 not .6 since it's a type II error and we are assuming the null hypothesis false Right? NEAS Supreme Being         Group: Administrators Posts: 4.3K, Visits: 1.3K +x MyriamSakr - 10/4/2019 3:11:09 PM+x tud55886 - 10/3/2019 6:09:46 PMThere is an error in 4.2 part B:i‌t should be Part B: β = 1-(P(0.6, N, 0) + P(0.6, N, 1) + P(0.6,N,2)), also the calculation is wrong.Also we should use p=.5 not .6 since it's a type II error and we are assuming the null hypothesis false Right?correct; we will correct the typos on this post. NEAS Supreme Being         Group: Administrators Posts: 4.3K, Visits: 1.3K +x tud55886 - 10/3/2019 5:59:42 PMThere is a mistake in exercise 4.1 part B: i‌t should be β = 1-(P(0.6, N, N-1) + P(0.6, N, N)), the calculation is correct but the formula is wrong. [NEAS: Thank you; typos corrected.]
##### Merge Selected
Merge into selected topic...

Merge into merge target...

Merge into a specific topic ID...