* Your assessment is very important for improving the workof artificial intelligence, which forms the content of this project
Download Slides 2-7 Hypothesis Testing
Foundations of statistics wikipedia , lookup
History of statistics wikipedia , lookup
Degrees of freedom (statistics) wikipedia , lookup
Confidence interval wikipedia , lookup
Bootstrapping (statistics) wikipedia , lookup
Taylor's law wikipedia , lookup
Resampling (statistics) wikipedia , lookup
BA 275 Quantitative Business Methods Agenda Statistical Inference: Hypothesis Testing Type I and II Errors Power of a Test Hypothesis Testing Using Statgraphics 1 Type I, II Errors, and Power a = P( Type I Error ) = P( reject H0 given that H0 is true) b = P( Type II Error ) = P( fail to reject H0 given that H0 is false) Power = 1 – b = P( reject H0 given that H0 is false ) Refer to textbook p. 416 2 Example 1 You want to see if a redesign of the cover of a mail- order catalog will increase sales. Assume that the mean sales from the new catalog will be approximately normal with s = $50 and that the mean for the original catalog will be m = $25. Given a sample of size n = 900, you wish to test H0: m = 25 vs. Ha: m > 25. Rejection region is: reject H0 if the sample mean > 26. Q1: Find a = P( Type I error ). Q2: Find b = P( Type II error ) given m = $28. Q3: Find b = P( Type II error ) given m = $30. 3 Example 2 A survey of 100 retailers was conducted to see if the mean after-tax profit exceeded $70,000. Assume that the population standard deviation is $20,000. Q1. Let rejection region be: Rejection H0 if the sample mean exceeds $73,290. Find a. Q2. Calculate the power of the test given that the true m = 75,500? Q3. Suppose the sample mean is $75,000. Find the pvalue. Q4. Estimate the true mean after-tax profit using a 95% confidence interval. 4 Hypothesis Testing Using SG Steps are similar to what you did for Confidence Interval Estimation. Use the right mouse button for more options. For example, to change the significance level (the value of a) and/or to select the type of tests (lower, upper, or two-tailed test.) Refer to page 3 of the SG instruction for interval estimation (filename: SG Instruction Estimation.doc downloadable from the class website) on how to select a subset of sample for analysis. 5 Central Limit Theorem (CLT) The CLT applied to Means If X ~ N ( m , s 2 ) , then X ~ N ( m , s2 ). n If X ~ any distribution with a mean m, and variance s2, then X ~ N ( m , What if s is unknown? What if s is unknown and n is small? s2 n ) given that n is large. With a large n, approximate s with s. The CLT still holds. Need to modify the CLT. 6 Central Limit Theorem (CLT) s is unknown but n is large s 2 s If X ~ N ( m , s ) , then X ~ N ( m , ) . N ( m , ) n n 2 2 If X ~ any distribution with a mean m, and variance s2, then X ~ N ( m , s2 n ) given that n is large. s2 N (m , ) n 7 Central Limit Theorem (CLT) s is unknown and n is small s2 X ~ t ( m , ) with degrees of freedom n 1. n If X ~ N ( m , s 2 ) , then X ~ N ( m , s2 ). n If X ~ any distribution with a mean m, and variance s2, then X ~ N ( m , s2 n ) given that n is large. 8 T distribution with degrees of freedom 5 vs. Normal(0, 1) 9 Example 3 A random sample of 10 one-bedroom apartments (Ouch, a small sample) from your local newspaper gives a sample mean of $541.5 and sample standard deviation of $69.16. Assume a = 5%. Q1. Does the sample give good reason to believe that the mean rent of all advertised apartments is greater than $500 per month? (Need H0 and Ha, rejection region and conclusion.) Q2. Find the p-value. Q3. Construct a 95% confidence interval for the mean rent of all advertised apartments. Q4. What assumption is necessary to answer Q1-Q3. 10 T Table (Table D) 11 Answer Key to Examples Used Example 1 Q1. a = P( reject H0 given that H0 is true ) = P( 26 25 = P( Z ) = 0.2743. 50 / 900 X > 26 given that m = 25 ) Q2. b = P( fail to reject H0 given that H0 is false ) = P( 26 28 = P( Z ) = 0.1151. 50 / 900 X < 26 given that m = 28 ) Q3. b = P( fail to reject H0 given that H0 is false ) = P( X < 26 given that m = 30 ) 26 30 = P( Z ) = 0.0082. 50 / 900 12 Answer Key to Examples Used Example 2 Q1. a = P( reject H0 given that H0 is true ) = P( 73290 70000 = P( Z ) = 0.05. 20000 / 100 X > 73290 given that m = 70000 ) Q2. b = P(fail to reject H0 given that H0 is false) = P( X < 73290 given that m = 75500 ) 73290 75500 = P( Z ) = 0.1335. Power = 1 – b = 0.8665. 20000 / 100 Q3. p-value = P( getting a sample mean $75,000 or more extreme given that m = 70000 ) 75000 70000 = P( Z ) = 0.0062. Reject H0. 20000 / 100 20000 Q4. 75000 (1.96)( ) 100 13 Answer Key to Examples Used Example 3 Q1. H0: m = 500 vs. Ha: m > 500. Rejection region: reject H0 if t x 500 1.833 . s/ n 1.833 comes from Table D with a = 0.05 and df = n – 1 = 9. Since the sample mean 541.5 has a t score = 1.8975 (in the rejection region), we concluded that m > 500, i.e., reject H0. Q2. We rejected H0 with a = 0.05 but will not reject H0 if a = 0.025. This implies that the p-value must fall between 0.025 and 0.05. 69.16 Q3. 541.5 2.262 10 Q4. all rents advertised follow a normal distribution, i.e., the population distribution is normal X ~ N ( m , s 2 ). 14