This preview shows page 1. Sign up to view the full content.
Unformatted text preview: BASIC BUSINESS STATISTICS Eleventh Edition Berenson Levine Krehbiel Slides Modified by Eugene Li Slide 1 Topic 1 (Part 2) Hypothesis Testing about Mean and Proportion for One Population
s s s s s Developing Null and Alternative Hypotheses and Type I and Type II Errors Tests About a Population Mean: LargeSample Case Tests About a Population Mean: SmallSample Case Tests About a Population Proportion (9.19.4) Slide 2 Developing Null and Alternative Hypotheses
s s Hypothesis testing can be used to determine whether a statement about the value of a population parameter should or should not be rejected. The null hypothesis, denoted by H0 , is a tentative assumption about a population parameter. The alternative hypothesis, denoted by Ha , is the opposite of what is stated in the null hypothesis. (H1 is used instead of Ha in the textbook) Hypothesis testing is similar to a criminal trial. The hypotheses are: H0: The defendant is innocent
o ve o proH : The defendant is guilty t a want u Slide 3 s s his y what is Developing Null and Alternative Hypotheses
s s If you reject H0, you have statistical proof that the Ha is correct. If you do not reject H0, you have failed to proof Ha is correct. This failure; however, DOES NOT mean you have proved the H0 is correct. Both H0 and H0 must be about the parameter. Equal sign will be included into H0, that means =, ≤, and ≥. s s Slide 4 Concepts of Hypothesis Testing
s Assume the null hypothesis is true (µ = 350). µ = 350 • Sample from the demand population, and build a statistic related to the parameter hypothesized (the sample mean). • Pose the question: How probable is it to obtain a sample mean at least as extreme as the one observed from the sample, if H0 is correct? Slide 5 Concepts of Hypothesis Testing
s Assume the null hypothesis is true (µ = 350). x = 355 µ = 350 x = 450 • Since the is much larger than 350, the mean µ is likely to x be greater than 350. Reject the null hypothesis. • Since the is not much larger, i.e. close to 350, then the x mean µ is not likely to be greater than 350. Fail to reject the null hypothesis. Slide 6 A Summary of Forms for Null and Alternative Hypotheses about a Population Mean
s s The equality part of the hypotheses always appears in the null hypothesis. In general, a hypothesis test about the value of a population mean µ must take one of the following three must take one of the following three forms (where µ 0 is the hypothesized value of the population mean). H0: µ ≥ µ 0 H0: µ ≤ µ 0 H0: µ = µ 0 Ha: µ < µ 0 Ha: µ > µ 0 Ha: µ ≠ µ 0 (righttail) (twotail) (lefttail) Slide 7 Example: Metro EMS
A major west coast city provides one of the most comprehensive emergency medical services in the world. Operating in a multiple hospital system with approximately 20 mobile medical units, the service goal is to respond to medical emergencies with a mean time of 12 minutes or less. The director of medical services wants to formulate a hypothesis test that could use a sample of emergency response times to determine whether or not the service goal of 12 minutes or less is being achieved. If more than 12 minutes, followup action is required. Slide 8 Example: Metro EMS
Hypotheses H0: µ ≤ 1 2 Conclusion and Action The emergency service is meeting the response goal; no followup action is necessary. Ha: µ > 1 2 The emergency service is not meeting the response goal; appropriate followup action is necessary. where µ is the mean response time for the population of medical emergency requests. Slide 9 Type I and Type II Errors
s s s s s s Since hypothesis tests are based on sample data, we must allow for the possibility of errors. A Type I error is rejecting H0 when it is true. A Type II error is accepting H0 when it is false. The person conducting the hypothesis test specifies the maximum allowable probability of making a Type I error, denoted by α and called the level of significance. Generally, we cannot control for the probability of making a Type II error, denoted by β . Statisticians avoid the risk of making a Type II error by using “fail to (or do not) reject H0” and not “accept H0”. “Do not reject” isn’t the same as “Accept”! Slide 10 Example: Metro EMS
s Type I and Type II Errors Conclusion (µ > 1 2 ) Accept H0 (Conclude µ ≤ 1 2 ) Reject H0 (Conclude µ > 1 2 ) Population Condition H0 True Ha True (µ ≤ 1 2 ) Correct Type II Error Correct Conclusion Slide 11 Conclusion Type I Εrror OneTailed Tests About a Population Mean: Large Sample Case (n > 30)
s Hypotheses: H0: µ ≤ µ 0 or or H0: µ ≥ µ 0 Ha: µ > µ 0 Ha: µ < µ 0
s Test Statistic: (exact) s z = x −µ σ/ n
0 σ Known Known x −µ z= s/ n σ Unknown
0 (approximate) (Textbook uses t) Rejection Rule: Reject H0 if z > zα Reject H0 if z < zα Reject Slide 12 Example: Metro EMS
s OneTailed Test about a Population Mean Let α = P (Type I Error) = .05 = Sampling distribution x of (assuming H0 is true and µ ≤ 12) Do Not Reject H0 1.645σ x 12 c (Decision point) Reject H0 α = .0 5
x Slide 13 Example: Metro EMS
s OneTailed Test about a Population Mean x Let n = 40, = 13.25 minutes, s = 3.2 minutes (The sample standard deviation s can be used to estimate the population standard deviation σ .)
z= x − µ 13.25 −12 = = 2.47 s/ n 3.2 / 40 Since 2.47 > 1.645, we reject H0. Conclusion: We are enough evidence that Metro EMS is not meeting the response goal of 12 minutes; appropriate action should be taken to improve service. Slide 14 s There are two approaches to test whether the sample mean supports the alternative hypothesis (Ha) • The critical value (or decision point) method is mandatory for manual testing (but can be used when testing is supported by a statistical software) • The pvalue method which is mostly used when a statistical software is available. Approaches to Testing Slide 15 The Use of p Values The pvalue is the probability of getting a test statistic equal to or more extreme than the sample result (the one computed), given that the null hypothesis is true.
s s The p value can beused to make the decision in a hypothesis test by noting that: • if the p value is less than the level of significance α, the value of the test statistic is in the rejection region. • if the p value is greater than or equal to α , the value , the value of the test statistic is not in the rejection region. Reject H0 if the pvalue < α . Slide 16 The Use of p Values
If the p value is very low, it is logical to reject the null hypothesis, don’t need to compare to the α. Very often you’ll see a pvalue of .0000 in SGC output, it doesn’t mean pvalue = 0, just too small and can’t be printed. This falls into what the above statement. s s Slide 17 Example: Metro EMS
s Using the p value to Test the Hypothesis x Recall that z = 2.47 for = 13.25. Then p value = .0068. Since p value < α, that is .0068 < .05, we reject H0. Do Not Reject H0 Reject H0 p value= .0 0 6 8 0 1.645 2.47 z Slide 18 Interpreting the pvalue
Because the probability that the sample mean will assume a value of at least 13.25 when µ ≤ 12 is so small (.0068), there are reasons to believe that µ > 12. Note how the event x ≥ 13.25 is rare under µ 0 12, H≤ when becomes more …it but... probable under Ha, when µ > 12 H 0 : µ ≤ 12 H1 : µ > 12 x = 13.25 Slide 19 The Steps of Hypothesis Testing
s s s s s State the appropriate hypotheses. Choose the level of significance α for the test. (Actually, also choose the appropriate sample size and the Type II Error β !) Determine the appropriate test statistic and the sampling distribution Use α to develop the rule for rejecting H0. to develop the rule for rejecting Collect the sample data and compute the value of the test statistic. (a) Compare the test statistic to the critical value(s) in the rejection rule, or (b) Compute the p value based on the test statistic and compare it to α , to determine whether or to determine whether or not to reject H0. s Slide 20 TwoTailed Tests About a Population Mean: Large Sample Case (n > 30)
s Hypotheses: Ha: µ ≠ µ0 H0: µ = µ 0 s Test Statistic: x−µ z= σ/ n
0 σ Known Known σ Unknown z = x −µ s/ n 0 s Rejection Rule: Reject H0 if z > zα/2 Slide 21 Example: Glow Toothpaste
The production line for Glow toothpaste is designed to fill tubes of toothpaste with a mean weight of 6 ounces. Data available show that the weight has a standard deviation of .2 ounces. Periodically, a sample of 30 tubes will be selected in order to check the filling process. Quality assurance procedures call for the continuation of the filling process if the sample results are consistent with the assumption that the mean filling weight for the population of toothpaste tubes is 6 ounces; otherwise the filling process will be stopped and adjusted. Slide 22 Example: Glow Toothpaste
A hypothesis test about the population mean can be used to help determine when the filling process should continue operating and when it should be stopped and corrected. The hypotheses are: H0: µ = 6 Ha: µ ≠6 With a .05 level of significance, the decision rule is: With a .05 level of significance, the decision rule is: Reject H0 if z < 1.96 or if z > 1.96 Slide 23 Example: Glow Toothpaste
s TwoTailed Test about a Population Mean Sampling distribution x of (assuming H0 is true and µ = 6) Reject H0 Do Not Reject H0 Reject H0 α /2 = .0 2 5 1.96 0 1.96 z Slide 24 Example: Glow Toothpaste
s TwoTailed Test about a Population Mean Assume that a sample of 30 toothpaste tubes provides a sample mean of 6.1 ounces. x Let n = 30, = 6.1 ounces, σ = .2 ounces x − µ0 6. 1 − 6
z= σ/ n = .2 / 30 = 2.74 Since 2.74 > 1.96, we reject H0. Conclusion: We have enough evidence to conclude that the actual average filling weight of the toothpaste tubes is not 6 ounces. The filling process should be stopped and the filling mechanism adjusted. Slide 25 Example: Glow Toothpaste
s Using the p Value for a TwoTailed Hypothesis Test Suppose we define the p value for a twotailed test as double the area found in the tail of the distribution. With z = 2.74, the standard normal probability table shows there is a .5000 .4969 = .0031 probability of a difference larger than .1 in the upper tail of the distribution. Considering the same probability of a larger difference in the lower tail of the distribution, we have p value = 2(.0031) = .0062 The p value .0062 is less than α = .05, so H0 is rejected. Slide 26 Hypothesis Testing of a Population Mean: SmallSample Case (n < 30)
s s s If the variable of the population is not normally distributed: • One option is to increase the sample size to n > 30 and use the largesample hypothesis testing procedures; another option is to use nonparametric methods discussed in Topic 3. If the variable of the population is normally distributed and σ is is known: • The largesample hypothesis testing procedure can be used. If the variable of the population is normally distributed and σ is unknown: • The appropriate test is based on a probability distribution known as the t distribution. • Note: Even n ≥ 30, you should still use t if the σ is unknown. Slide 27 Tests About a Population Mean: SmallSample Case (n < 30)
s Test Statistic: σ Unknown x −µ t= s/ n
0 s This test statistic has a t distribution with n 1 degrees of freedom. Rejection Rule: OneTailed TwoTailed Ha: µ > µ 0 Reject H0 if t > tα Ha: µ < µ 0 Reject H0 if t < tα Ha: µ ≠ µ 0 Reject H0 if t > tα/2 Slide 28 Example: Use the Glow Toothpaste again
The production line for Glow toothpaste is designed to fill tubes of toothpaste with a mean weight of 6 ounces. Periodically, a sample of 25 tubes will be selected in order to check the filling process. Quality assurance procedures call for the continuation of the filling process if the sample results are consistent with the assumption that the mean filling weight for the population of toothpaste tubes is 6 ounces; otherwise the filling process will be stopped and adjusted. Slide 29 Example: Use the Glow Toothpaste again
A hypothesis test about the population mean can be used to help determine when the filling process should continue operating and when it should be stopped and corrected. The hypotheses are: H0: µ = 6 Ha: µ ≠6 We perform a test with a .05 level of significance. We perform a test with a .05 level of significance. Slide 30 Example: Use the Glow Toothpaste again
s TwoTailed Test about a Population Mean Assume that a sample of 25 toothpaste tubes provides a sample mean of 6.1 ounces and a sample std. dev. = 0.2 ounces x Let n = 25, = 6.1 ounces, s = 0.2 ounces x − µ0 6.1 − 6 t= = = 2.50
s/ n .2 / 25 Since 2.50 > 2.064, we reject H0. Conclusion: We have enough evidence to conclude that the mean filling weight of the toothpaste tubes is not 6 ounces. The filling process should be stopped and the filling mechanism adjusted. Slide 31 p Values and the t Distribution s s s The format of the t distribution table provided in most statistics textbooks does not have sufficient detail to determine the exact p value for a hypothesis test. However, we can still use the t distribution table to identify a range for the p value. An advantage of computer software packages is that the computer output will provide the p value for the t distribution. Slide 32 Example: Use the Glow Toothpaste again
s Using the p Value for a TwoTailed Hypothesis Test Suppose we define the p value for a twotailed test as double the area found in the tail of the distribution. With t = 2.50 (and there is 24 d.f.), the ttable shows the probability is in between 0.01 and 0.005 and closer to 0.01. Roughly we can say 0.0094. Therefore, we have p value = 2(.0094) = .0188 The p value .0188 is less than α = .05, so H0 is rejected. Slide 33 Hypothesis Test about a Population Proportion
When the population consists of nominal data, the only inference we can make is about the proportion of occurrence of a certain value. The parameter π was used before to calculate these probabilities under the binomial distribution. s s Slide 34 Hypothesis Test about a Population Proportion
s Statistic and sampling distribution • the statistic used when making inference about p is: x p= where n x − the number of successes. n − sample size. – Under certain conditions, [n≥30, nπ > 5 and n(1π ) > p is approximately normally distributed, with µ = π and σ 2 = π (1  π )/n, from previous topic! Slide 35 s s The equality part of the hypotheses always appears in the null hypothesis. In general, a hypothesis test about the value of a population proportion π must take one of the following three forms (where π 0 is the hypothesized value of the population proportion). H0: π ≥ π 0 A Summary of Forms for Null and Alternative Hypotheses about a Population Proportion H0: π ≤ π 0 H0: π = π 0 Ha: π < π 0 Ha: π > π 0 Ha: π ≠ π 0 < Slide 36 Tests About a Population Proportion: LargeSample Case (n > 30, nπ 0 > 5 and n (1 – π 0) > 5)
s Test Statistic: z=
where p− 0 π σp
n σp =
s π0 (1 −π0 ) Rejection Rule: OneTailed Ha: π > π 0 Reject H0 if z > zα Ha: π < π 0 Reject H0 if z < zα Ha: π ≠ π 0 zα/2 Reject H0 if z > Slide 37 TwoTailed Hypothesis Test about a Population Proportion s Example (Predicting the winner in election day) • Voters are asked by a certain network to participate in an exit poll in order to predict the winner on election day. • A sample of 765 voters were drawn and 407 have voted for Conservatives, can the network conclude that the Conservatives’ candidate will win the election? Slide 38 Hypothesis Test about a Population Proportion
s Solution • The problem objective is to describe the population of votes in the state. • The data are nominal. • The parameter to be tested is ‘π ’.. ’ • Success is defined as “Vote Conservatives”. • The hypotheses are: H0: π ≤ .5 .5 Ha: π > .5 More than 50% vote Conservatives Slide 39 Hypothesis Test about a Population Proportion
• Solving by hand • Check the conditions! • The rejection region is z > zα = z.05 = 1.645. • From file we count 407 success. Number of voters participating is 765. p = 407 765 = .532 • The sample proportion is • The value of the test statistic is p −π0 .532 − .5 Z= = = 1.77 π 0 (1 − π 0 ) / n .5(1 − .5) / 765
• The pvalue is = P(Z>1.77) = .0382 Slide 40 Hypothesis Test about a Population Proportion in terms of Number of Events of Interest
The previous problem can be one in this way too… instead of using proportion, we use….. H0: N ≤ 382.5 Ha: N > 382.5 (Why 382.5?) 407 − 382.5 24.5 Z= = = 1.77 382.5(1 − 382.5) 13.8293
The pvalue is = P(Z>1.77) = .0382. Hence the result is the same as before. Slide 41 What if …..
…..we have a small sample size or any of the requirements isn’t fulfilled? Can we still use z as the test statistic? s We will discuss with an example in class written on the board.
s Slide 42 Don’t Forget….. Check the Requirements!!!! Slide 43 The End of Topic 1 (part 2) Slide 44 ...
View
Full
Document
This note was uploaded on 01/17/2010 for the course STATS 2225 taught by Professor Li during the Spring '09 term at Langara.
 Spring '09
 Li
 Statistics

Click to edit the document details