Decision Errors and Power When we perform a

  • Slides: 20
Download presentation
Decision Errors and Power • When we perform a statistical test we hope that

Decision Errors and Power • When we perform a statistical test we hope that our decision will be correct, but sometimes it will be wrong. There are two types of incorrect decisions. To help distinguish these two types of error, we give them specific names. • The error made by rejecting the null hypothesis H 0 (accepting Ha) when in fact H 0 is true is called a type I error. • The probability of making a type I error is denoted by . • The error made by accepting the null hypothesis H 0 (rejecting Ha) when in fact H 0 is false is called a type II error. • The probability of making a type II error is denoted by . • The probability that a fixed level significant test will reject H 0 when a particular alternative value of the parameter is true is called the power of the test to detect that alternative. week 9 1

 • Significance and type I error The significance level of any fixed level

• Significance and type I error The significance level of any fixed level test is the probability of a Type I error. That is the probability that the test will reject the null hypothesis H 0 when H 0 is in fact true. • Power and Type II error The power of a fixed level test against a particular alternative is Power = 1 - β = 1 - P( not rejecting H 0 when H 0 is false) = = P( rejecting H 0 when H 0 is false) week 9 2

Ways to increase Power • Increase α. When we increase α the strength of

Ways to increase Power • Increase α. When we increase α the strength of evidence required for the rejection is less. • Consider a particular Ha that is farther away from μ 0. Values of μ that are in Ha but lie close to μ 0 are harder to detect (lower power) then values of μ that are far from μ 0. • Increase sample size. More data will provide more information about the population so we have a better chance of distinguishing values of µ. • Decrease σ. This has the same effect as increasing the sample size: more information about µ. Improving the measurement process and restricting attention to a subpopulation are two common ways to decrease σ. week 9 3

Example • We are interested to learn about the mean contents of cola bottles

Example • We are interested to learn about the mean contents of cola bottles and want to test the following hypotheses: H 0: = 300 Ha: < 300. • The sample size is n = 6, and the population is assumed to have a normal distribution with = 3. A 5% significance test rejects H 0 if z ≤ Z 0. 05 = -1. 645 where the test statistic z is • Power calculations help us see how large a shortfall in the bottle contents the test can be expected to detect. (a) Find the power of this test against the alternative = 299. (b) Find the power against the alternative = 295. (c) Is the power against = 290 higher or lower than the value you found in (b)? Explain why this result makes sense. week 9 4

Solution week 9 5

Solution week 9 5

Exercise • You have an SRS of size n = 9 from a normal

Exercise • You have an SRS of size n = 9 from a normal distribution with σ = 1. You wish to test the following H 0: = 0 Ha: > 0 • You decide to reject H 0 if and to accept H 0 otherwise. (a) Find the probability of a Type I error, that is, the probability that your test rejects H 0 when in fact = 0. (b) Find the probability of a Type II error when = 0. 3. This is the probability that your test accepts H 0 when in fact = 0. 3. (c) Find the probability of a Type II error when = 1. week 9 6

Qestion 17 Final Exam Dec 2000 When testing H 0: μ = 5 vs

Qestion 17 Final Exam Dec 2000 When testing H 0: μ = 5 vs Ha: μ ≠ 5 at = 0. 01 with n =40 suppose that the probability of a type II error ( ) is equal to 0. 02 when = 2. Which of the following statements are true? a) > 0. 02 when = 3 b) > 0. 02 if the sample size was 50 (at = 2) c) > 0. 02 if had been twice as large. (at = 2) d) The power of the test is at = 2 is 0. 99 week 9 7

Exercise A study was carried out to investigate the effectiveness of a treatment. 1000

Exercise A study was carried out to investigate the effectiveness of a treatment. 1000 subjects participated in the study, with 500 being randomly assigned to the "treatment group" and the other 500 to the "control (or placebo) group". A statistically significant difference was reported between the responses of the two groups (P <0. 005). State whether the following statements are true of false. a) There is a large difference between the effects of the treatment and the placebo. b) There is strong evidence that the treatment is very effective. c) There is strong evidence that there is some difference in effect between the treatment and the placebo. d) There is little evidence that the treatment has some effect. e) The probability that the null hypothesis is true is less than 0. 005. week 9 8

Use and abuse of Tests • The spirit of a test of significance is

Use and abuse of Tests • The spirit of a test of significance is to give a clear statement of the degree of evidence provided by the sample against the null hypothesis. The P-value does this. There is no sharp evidence between “significant” and “not significant” only increasingly strong evidence as the P-value decreases. • When large samples are available, even tiny deviations from the null hypothesis will be significant (small P-value). Statistically significant effect need not be practically important. Always plot the data and examine them carefully. Beware of outliers. • On the other hand, lack of significant does not imply that H 0 is true, especially when the test has low power. When planning a study, verify that the test you plan to use does have high probability of detecting an effect of the size you hope to find. week 9 9

 • Significant tests are not always valid. Faulty data collection, outliers in the

• Significant tests are not always valid. Faulty data collection, outliers in the data, and testing a hypothesis on the same data that first suggested that hypothesis can invalidate a test. Many tests run at once will probably produce some significant results by chance alone, even if the null hypotheses are true. • The reasoning behind statistical significance works well if you decide what effect you are seeking, design an experiment or sample to search for it, and use a test of significance to weight the evidence you get. week 9 10

Example Suppose that the population of scores of the high school seniors that took

Example Suppose that the population of scores of the high school seniors that took the SAT-Verbal test this year follows a normal distribution with = 48 and = 90. A report claims that 10, 000 students who took part in the national program for improving SAT-verbal scores had a significantly better score (at the 5% level of sig. ) than the population as a whole. In order to determine if the improvement is of practical significance one should: Ø Find out the actual mean score for the 10, 000 students. Ø Fine out the actual p-value. week 9 11

The t distribution • Suppose that a SRS of size n is drawn from

The t distribution • Suppose that a SRS of size n is drawn from a N(μ, σ) population. Then the one sample t statistic has a t distribution with n -1 degrees of freedom. • The t distribution has mean 0 and it is a symmetric distribution. • There is a different t distribution for each sample size. • A particular t distribution is specified by the degrees of freedom that comes from the sample standard deviation. week 9 12

Tests for the population mean when is unknown • Suppose that a SRS of

Tests for the population mean when is unknown • Suppose that a SRS of size n is drawn from a population having unknown mean μ and unknown stdev. . To test the hypothesis H 0: μ = μ 0 , we first estimate by s – the sample stdev. , then compute the one-sample t statistic given by • In terms of a random variable T having the t (n - 1) distribution, the P-value for the test of H 0 against Ha : μ > μ 0 is Ha : μ < μ 0 is P( T ≥ t ) P( T ≤ t ) Ha : μ ≠ μ 0 is 2·P( T ≥ |t|) week 9 13

Example • In a metropolitan area, the concentration of cadmium (Cd) in leaf lettuce

Example • In a metropolitan area, the concentration of cadmium (Cd) in leaf lettuce was measured in 6 representative gardens where sewage sludge was used as fertilizer. The following measurements (in mg/kg of dry weight) were obtained. Cd 21 38 12 15 14 8 Is there strong evidence that the mean concentration of Cd is higher than 12. Descriptive Statistics Variable Cd N 6 Mean 18. 00 Median 14. 50 Tr. Mean 18. 00 St. Dev 10. 68 SE Mean 4. 36 • The hypothesis to be tested are: H 0: μ = 12 vs Ha: μ > 12. week 9 14

 • The test statistics is: The degrees of freedom are df = 6

• The test statistics is: The degrees of freedom are df = 6 – 1 = 5 Since t = 1. 38 < 2. 015, we cannot reject H 0 at the 5% level and so there are no strong evidence. The P-value is 0. 1 < P(T(5) ≥ 1. 38) < 0. 15 and so is greater then 0. 05 indicating a non significant result. week 9 15

CIs for the population mean when unknown • Suppose that a SRS of size

CIs for the population mean when unknown • Suppose that a SRS of size n is drawn from a population having unknown mean μ. A C-level CI for μ when is unknown is an interval of the form where t* is the value for the t (n -1) density curve with area C between –t* and t*. • Example: Give a 95% CI for the mean Cd concentration. week 9 16

 • MINITAB commands: Stat > Basic Statistics > 1 -Sample t • MINITAB

• MINITAB commands: Stat > Basic Statistics > 1 -Sample t • MINITAB outputs for the above problem: T-Test of the Mean Test of mu = 12. 00 vs mu > 12. 00 Variable N Mean St. Dev Cd 6 18. 00 10. 68 SE Mean 4. 36 T 1. 38 P 0. 11 T Confidence Intervals Variable Cd N 6 Mean 18. 00 St. Dev 10. 68 week 9 SE Mean 4. 36 95. 0 % CI (6. 79, 29. 21) 17

Question 3 Final exam Dec 2000 • In order to test H 0: μ

Question 3 Final exam Dec 2000 • In order to test H 0: μ = 60 vs Ha: μ ≠ 60 a random sample of 9 observations (normally distributed) is obtained, yielding and s = 5. What is the p-value of the test for this sample? a) b) c) d) e) greater than 0. 10. between 0. 05 and 0. 10. between 0. 025 and 0. 05. between 0. 01 and 0. 025. less than 0. 01. week 9 18

Question A manufacturing company claims that its new floodlight will last 1000 hours. After

Question A manufacturing company claims that its new floodlight will last 1000 hours. After collecting a simple random sample of size ten, you determine that a 95% confidence interval for the true mean number of hours that the floodlights will last, , is (970, 995). Which of the following are true? (Assume all tests are two-sided. ) I) At any <. 05, we can reject the null hypothesis that the true mean is 1000. II) If a 99% confidence interval for the mean were determined here, the numerical value 972 would certainly lie in this interval. III) If we wished to test the null hypothesis H 0: = 988, we could say that the p-value must be < 0. 05. week 9 19

Questions 1. Alpha (level of sig. α) is a) the probability of rejecting H

Questions 1. Alpha (level of sig. α) is a) the probability of rejecting H 0 when H 0 is true. b) the probability of supporting H 0 when H 0 is false. c) supporting H 0 when H 0 is true. d) rejecting H 0 when H 0 is false. 2. Confidence intervals can be used to do hypothesis tests for a) left tail tests. b) right tail tests c) two tailed test 3. The Type II error is supporting a null hypothesis that is false. T/F week 9 20