Survey
* Your assessment is very important for improving the workof artificial intelligence, which forms the content of this project
* Your assessment is very important for improving the workof artificial intelligence, which forms the content of this project
Chapter Four (continued) 1/42 introduction Attention is now turned from descriptive to inferential statistics. You will be introduced to two forms of inference, namely, hypothesis testing and confidence intervals. We begin with hypothesis testing. 4.3 Hypothesis Testing (continued) 2/42 Rationale and Method Hypothesis testing is essentially a method for decision making. The decision relates to the choice between two competing, mutually exclusive, statements regarding one or more population parameters. 4.3 Hypothesis Testing (continued) 3/42 Rationale and Method (continued) The competing statements of fact are referred to respectively as the null and alternative hypotheses. The null hypothesis, symbolized H0 , is a precise statement concerning the parameter(s) of interest while the alternative hypothesis, symbolized HA , is a less precise competing statement. 4.3 Hypothesis Testing (continued) 4/42 Rationale and Method (continued) For example, the null hypothesis might state that the mean of the population (µ) is equal to 100 while the less concise alternative might assert that the mean is greater than 100. 4.3 Hypothesis Testing (continued) 5/42 Rationale and Method (continued) The decision as to whether the assertion of the null hypothesis is to be abandoned and the alternative assertion adopted as the true condition is made by using a model of the sampling distribution of the involved statistic to establish a decision criterion. If the criterion is met the null hypothesis is rejected in favor of the alternative assertion. If the criterion is not met the null statement is retained. 4.3 Hypothesis Testing (continued) 6/42 Rationale and Method (continued) The test is conducted under the assumption that the null hypothesis is true. Thus, the model used has the mean value specified by the null hypothesis which is symbolized µ0 . µ0 = 100 might be specified for example. 4.3 Hypothesis Testing (continued) 7/42 Rationale and Method (continued) A small region in the tail of the curve, termed the critical region, is specified. The size of this region is symbolized by α (alpha). Alpha is traditionally set at .05 or .01 but may be set at other levels if so desired. The placement and size of the critical region are not arbitrary. The region is designed to fulfill two criteria. 4.3 Hypothesis Testing (continued) 8/42 Rationale and Method (continued) First, the probability that the sample mean will take a value in the critical region is small if the null hypothesis is true. Second, the probability that the test statistic will take a value in the critical region must increase when the null hypothesis is false. More specifically, as the difference between µ0 and µ increases, the probability of the test statistic being in the critical region must also increase. 4.3 Hypothesis Testing (continued) 9/42 Rationale and Method (continued) The null hypothesis is rejected if the test statistic is in the critical region. The null hypothesis is not rejected if the test statistic is not in the critical region. 4.3 Hypothesis Testing (continued) 10/42 Rationale and Method (continued) Figure: Example model for an hypothesis test. fail to reject H0 critical size of region critical region (.05) test statistic (x) 4.3 Hypothesis Testing (continued) reject H 0 11/42 Rationale and Method (continued) How do you know if the test statistic is in the critical region? p-value vs alpha method. Obtained value versus critical value method. 4.3 Hypothesis Testing (continued) 12/42 The One Mean Z Test The one mean Z test is used to test null hypotheses of the form H0 : µ = µ0 . The alternative hypothesis will take one of two forms referred to as one-tailed or two-tailed. 4.3 Hypothesis Testing (continued) 13/42 One And Two-Tailed Alternatives The one-tailed alternative hypothesis will take one (not both) of the following forms. HA : µ < µ0 HA : µ > µ0 The two-tailed alternative hypothesis takes the form HA : µ 6= µ0 4.3 Hypothesis Testing (continued) 14/42 The Test Statistic The test statistic used to conduct the one mean Z test takes the form Z= x̄ − µ0 √σ n where x̄ is the sample mean, µ0 is the hypothesized mean of the population, σ is the population standard deviation and n is the sample size. 4.3 Hypothesis Testing (continued) 15/42 p-Values For One-Tailed Tests Calculation of p-values for one-tailed tests depends on the form of the alternative hypothesis. For tests with alternatives of the form HA : µ < µ0 the p-value is the area below (i.e. to the left of) Z . For tests with alternatives of the form HA : µ > µ0 the p-value is the area above (i.e. to the right of) Z . 4.3 Hypothesis Testing (continued) 16/42 p-Values For Two-Tailed Tests The p-value for a two-tailed test is two times the area above Z if z is positive. two times the area below Z if Z is negative. 1.0 if Z equals zero. 4.3 Hypothesis Testing (continued) 17/42 Decision Rule For p-Value Vs. α Method When conducting the one mean Z test via the p-value versus α method: the null hypothesis is rejected in favor of the alternative when the p-value is less than or equal to α. the null hypothesis is not rejected if the p-value is greater than α. 4.3 Hypothesis Testing (continued) 18/42 Obtained Z Obtained Z for the one mean Z test is calculated by Z= 4.3 Hypothesis Testing (continued) x̄ − µ0 √σ n 19/42 Critical Z For One-Tailed Tests For tests with alternatives of the form HA : µ < µ0 critical Z is the Z value that cuts off α in the left-hand tail of the normal curve. For tests with alternatives of the form HA : µ > µ0 critical Z is the Z value that cuts off α in the right-hand tail of the normal curve. 4.3 Hypothesis Testing (continued) 20/42 Critical Z For Two-Tailed Tests Two-tailed tests have two critical values, one positive, the other negative. The critical values are the two Z scores that cut off α/2 in each tail of the curve. 4.3 Hypothesis Testing (continued) 21/42 Decision Rule For Obtained Vs. Critical Z Method For tests with alternatives of the form HA : µ < µ0 the null hypothesis is rejected in favor of the alternative if obtained Z is less than or equal to critical Z . If obtained Z is greater than critical Z the null hypothesis is not rejected. For tests with alternatives of the form HA : µ > µ0 the null hypothesis is rejected in favor of the alternative if obtained Z is greater than or equal to critical Z . If obtained Z is less than critical Z the null hypothesis is not rejected. 4.3 Hypothesis Testing (continued) 22/42 Decision Rule For Obtained Vs. Critical Z Method (continued) The null hypothesis for a two-tailed test is rejected if the absolute value of obtained Z is greater than or equal to the absolute value of critical Z . The null hypothesis is not rejected if the absolute value of obtained Z is less than to the absolute value of critical Z . 4.3 Hypothesis Testing (continued) 23/42 Example Use the information provided below to perform the indicated one mean Z test. H0 : µ = 120 HA : µ > 120 σ = 40 n = 150 x̄ = 128.2 α = .01 Justify your decision regarding the null hypothesis on the basis of both the p-value versus alpha and obtained Z versus critical Z methods. 4.3 Hypothesis Testing (continued) 24/42 Solution - p-Value Versus Alpha Method The Z value associated with 128.2 is Z= x̄ − µ0 √σ n = 128.2 − 120.0 40.0 √ 150 = 2.51. The p-value is the area above 128.2. Column three of Appendix A shows that the area above Z = 2.51 is .0060. Because this value is less than α = .01, the null hypothesis is rejected. 4.3 Hypothesis Testing (continued) 25/42 Solution - obtained Z versus critical Z Method Column three of the normal curve table shows that the closest value to.01 is .0099 which has an associated Z value of 2.33. Thus, the Z value at the leading edge of the critical region is 2.33. Because obtained Z of 2.51 is larger than critical Z of 2.33, the null hypothesis is rejected. 4.3 Hypothesis Testing (continued) 26/42 Example Use the information provided below to perform the indicated one mean Z test. H0 : µ = 1000 HA : µ < 1000 σ = 235 n = 180 x̄ = 985 α = .025 Justify your decision regarding the null hypothesis on the basis of both the p-value versus alpha and obtained Z versus critical Z methods. 4.3 Hypothesis Testing (continued) 27/42 Solution - p-Value Versus Alpha Method The Z value associated with 985 is Z= x̄ − µ0 √σ n = 985 − 1000 √235 180 = −.86. The p-value is the area below 985. Using Z = −.86 Column three of Appendix A shows this area to be .1949. Because .1949 is greater than .025, the null hypothesis is not rejected. 4.3 Hypothesis Testing (continued) 28/42 Solution - obtained Z versus critical Z Method Because a Z score of 1.96 cuts off .025 in the tail of the distribution and the critical region is below the mean of the distribution, critical Z is −1.96. Because −.86 is not less than −1.96, the null hypothesis is not rejected. 4.3 Hypothesis Testing (continued) 29/42 Example Use the information provided below to perform the indicated one mean Z test. H0 : µ = 80 HA : µ 6= 80 σ = 21 n = 40 x̄ = 87.1 α = .10 Justify your decision regarding the null hypothesis on the basis of both the p-value versus alpha and obtained Z versus critical Z methods. 4.3 Hypothesis Testing (continued) 30/42 Solution - p-Value Versus Alpha Method The Z value associated with 87.1 is Z= x̄ − µ0 √σ n = 87.1 − 80.0 √21 40 = 2.14. Because 87.1 is above the distribution mean of 80.0, the tail area is the area above 87.1 which reference to Appendix A shows to be .0162. The p-value is then p = 2 × .0162 = .0324 . Because p = .0324 < α = .10, the null hypothesis is rejected. The researcher can be confident (though not totally so) that the mean of the population is greater than 80. 4.3 Hypothesis Testing (continued) 31/42 Solution - obtained Z versus critical Z Method Critical Z values for a two-tailed test at α = .10 are the values that cut off .05 in each tail of the distribution. These values are ±1.65. Because the test statistic is 2.14 standard errors above the mean of the distribution and the right tail critical region begins at a point 1.65 standard errors above the mean of the distribution, the test statistic is clearly in the right tail critical region which means the null hypothesis is rejected. 4.3 Hypothesis Testing (continued) 32/42 Assumptions Assumptions underlying the one mean Z test Normality - sample is from a normally distributed population. Test is relatively robust against this violation and becomes increasingly so as sample size increases. Independence - each observation in the sample is unrelated to every other observation in the sample. Test is generally not robust against this violation. 4.3 Hypothesis Testing (continued) 33/42 The One Mean t Test The one mean Z and t tests test the same null hypotheses against the same alternatives. The primary difference between the two is that the Z test requires knowledge of σ, the population standard deviation, while the t test uses s an estimate of σ derived from the sample data. While obtained Z is referenced to a normal distribution, obtained t is referenced to a t distribution with n − 1 degrees of freedom. 4.3 Hypothesis Testing (continued) 34/42 The Test Statistic The test statistic used to conduct the one mean t test takes the form t= x̄ − µ0 √s n where x̄ is the sample mean, µ0 is the hypothesized population mean, s is the sample standard deviation and n is the sample size. 4.3 Hypothesis Testing (continued) 35/42 Example Use the sample data provided here to conduct the indicated one mean t test. H0 : µ = 8.0 Data = 6.0, 8.0, 5.5, 4.5, 8.5, 4.0, 3.5 HA : µ < 8.0 α = .01 4.3 Hypothesis Testing (continued) 36/42 Solution s P s= x)2 n s P x2 − ( n−1 = 2 251 − (40) 7 = 7−1 r 22.429 = 1.933 6 and 40 = 5.714. 7 By Equation 4.8 obtained t is then x̄ = t= x̄ − µ0 √s n 4.3 Hypothesis Testing (continued) = 5.714 − 8.00 1.933 √ 7 = −2.286 = −3.127. .731 37/42 Solution (continued) As can be seen from the table in Appendix B, a one-tailed test with degrees of freedom 7 − 1 = 6 conducted at α = .01 has an associated value of 3.143. As indicated by the alternative hypothesis, the critical region is in the lower tail so that the critical value is −3.143. Because the obtained value of −3.127 is greater than the critical value, the null hypothesis is not rejected. 4.3 Hypothesis Testing (continued) 38/42 Example Use the sample data provided here to conduct the indicated one mean t test. H0 : µ = 0.0 Data = −0.5, 1.0, 2.5, −1.0, 3.5, −0.5, 3.0, 2.5 HA : µ 6= 0.0 α = .10 4.3 Hypothesis Testing (continued) 39/42 Solution s s= P x)2 n s P x2 − ( n−1 = 2 36.25 − (10.50) 8 = 8−1 r 22.469 = 1.792 7 and 10.5 = 1.313. 8 By Equation 4.8 obtained t is then x̄ = t= 4.3 Hypothesis Testing (continued) x̄ − µ0 √s n = 1.313 1.792 √ 8 = 1.313 = 2.071. .634 40/42 Solution (continued) Critical t for a two-tailed test at α = .10 and seven degrees of freedom is ±1.895. Because 2.071 is greater than 1.895, the null hypothesis is rejected. 4.3 Hypothesis Testing (continued) 41/42 Assumptions Assumptions underlying the one mean t test are the same as those underlying the one mean Z test, namely Normality - sample is from a normally distributed population. Test is relatively robust against this violation and becomes increasingly so as sample size increases. Independence - each observation in the sample is unrelated to every other observation in the sample. Test is generally not robust against this violation. 4.3 Hypothesis Testing (continued) 42/42