1 / 31

Chapter 7: Hypothesis Testing

Chapter 7: Hypothesis Testing. A hypothesis is a conjecture about a population. Typically, these hypotheses will be stated in terms of a parameter. A test of hypothesis is a statistical procedure used to make a decision about the conjectured value of a parameter.

ita
Download Presentation

Chapter 7: Hypothesis Testing

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Chapter 7: Hypothesis Testing A hypothesis is a conjecture about a population. Typically, these hypotheses will be stated in terms of a parameter. A test of hypothesis is a statistical procedure used to make a decision about the conjectured value of a parameter. We will make our decision based on observed values of a statistic.

  2. The purpose of hypothesis testing is to determine whether there is enough statistical evidence in favor of a certain belief about a parameter. • Examples • Is there statistical evidence in a random sample of potential customers, that support the hypothesis that more than 10% of the potential customers will purchase a new products? • Is a new drug effective in curing a certain disease? A sample of patients is randomly selected. Half of them are given the drug while the other half are given a placebo. The improvement in the patients conditions is then measured and compared.

  3. The Hypotheses There are two hypotheses which we are comparing. The null hypothesis, H0, specifies a value of a parameter. This hypothesis is assumed to be true, and the collected data will be analyzed to see if it is contradictory to the null hypothesis. The alternative hypothesis, Ha, gives an opposing statement about the value of the parameter. The collected data will be analyzed to see if it supports the alternative hypothesis.

  4. Examples: Give the null hypothesis and the alternative hypothesis • You are investigating a complaint that “special delivery mail takes too much time” to be delivered • You want to show that people find the new design for a recliner chair more comfortable than the old design. • You are trying to show that cigarette smoke has an effect on the quality of a person’s life

  5. Examples: Give the null hypothesis and the alternative hypothesis • The mean age of the students enrolled in evening classes at a certain college is greater than 26 years. • The mean weight of packages shipped on Air Express during the past month was less than 36.7 lb. • The mean life of fluorescent light bulbs is at least 1600 hours. • The mean grade of a student in a statistics class is not 80.

  6. Concepts of Hypothesis Testing • The critical concepts of hypothesis testing. • Example: • An operation manager needs to determine if the mean demand during lead time is greater than 350. • If so, changes in the ordering policy are needed. • There are two hypotheses about a population mean: • H0: The null hypothesis m = 350 • Ha: The alternative hypothesis m > 350 This is what you want to prove

  7. Assume the null hypothesis is true (m= 350). m = 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?

  8. Since the is much larger than 350, the mean m is likely to be greater than 350. Reject the null hypothesis. Assume the null hypothesis is true (m= 350). m = 350 • In this case the mean m is not likely to be greater than 350. Do not reject the null hypothesis.

  9. Statistical Terminology Once the data is collected, we seek an answer to the question: “If the null hypothesis is true, how likely are we to observe this type of data, or data which is more extreme in the direction of the alternative hypothesis?” The observed significance level, or p-value of a test of hypothesis is the probability of obtaining the observed value of the sample statistic, or one which is even more supportive of the alternative hypothesis, under the assumption that the null hypothesis is true.

  10. Statistical Terminology For example, let’s assume that we are testing the hypothesis that the mean gas mileage for a certain type of car is 24 miles per gallon against an alternative that the mean is more than 24 mpg. H0: m = 24 mpg Ha: m > 24 mpg If a sample of 50 cars have a sample mean of 24.2 mpg, this gives a certain p-value. If the sample of 50 cars had a sample mean of 25.0 mpg, the p-value is even smaller, since this would be moreunusual to see if H0 is true (m = 24 mpg).

  11. Test Statistics and P-values Obviously, we must be able to calculate these p-values. A test statistic is a quantity calculated from the sampled value of a statistic, which is then used to calculate a p-value for a test of hypothesis. We recall that under appropriate conditions, we know the sampling distribution of the sample mean follows a normal distribution, and we can find a z-score using

  12. Decision Rule Based on the z-score calculated, we can determine how likely we are to get a sample mean (x-bar) like we observed or one more supportive of Ha. Decision Rule: This tells us when we feel the observed data provided sufficient evident to conclude the alternative hypothesis is true. It will be phrased as: Accept the alternative hypothesis when the p-value of the test is less than a. The value of a will be given in each exercise. It does NOT depend on the sample data. (More details later)

  13. Testing the Population Mean When the Population Standard Deviation is Known • Example • A new billing system for a department store will be cost- effective only if the mean monthly account is more than $170. • A sample of 400 accounts has a mean of $178. • If accounts are approximately normally distributed with s = $65, can we conclude that the new system will be cost effective?

  14. Testing the Population Mean (s is Known) • – Solution • The population of interest is the credit accounts at the store. • We want to know whether the mean account for all customers is greater than $170. Ha : m > 170 • The null hypothesis must specify a single value of the parameter m, H0 : m = 170

  15. The p-value of a test is the probability of observing a test statistic at least as extreme as the one computed, • given that the null hypothesis is true. • Let us demonstrate the concept on this example. P-value Method • The p-value provides information about the amount of statistical evidence that supports the alternative hypothesis.

  16. P-value Method The probability of observing a test statistic at least as extreme as 178, given that m = 170 is… The p-value

  17. Note how the event is rare under H0 when but... …it becomes more probable under H1, when Interpreting the p-value • Because the probability that the sample mean will assume a value of more than 178 when m = 170 is so small (.0069), there are reasons to believe that m > 170.

  18. Interpreting the p-value We can conclude that the smaller the p-value the more statistical evidence exists to support the alternative hypothesis.

  19. Interpreting the p-value • Describing the p-value • If the p-value is less than 1%, there is overwhelming evidence that supports the alternative hypothesis. • If the p-value is between 1% and 5%, there is a strong evidence that supports the alternative hypothesis. • If the p-value is between 5% and 10% there is a weak evidence that supports the alternative hypothesis. • If the p-value exceeds 10%, there is no evidence that supports the alternative hypothesis.

  20. The p-value a = 0.05 The p-value Method • The p-value can be used when making decisions based on rejection region methods as follows: • Define the hypotheses to test, and the required significance level a. • Perform the sampling procedure, calculate the test statistic and the p-value associated with it. • Compare the p-value to a. Reject the null hypothesis only if p-value <a; otherwise, do not reject the null hypothesis.

  21. Conclusions of a Test of Hypothesis • If we accept the alternative hypothesis, we conclude that there is enough evidence to infer that the alternative hypothesis is true. • If we do not accept the alternative hypothesis, we conclude that there is not enough statistical evidence to infer that the alternative hypothesis is true. The alternative hypothesis is the more important one. It represents what we are investigating.

  22. Another Example Historically, the mean GPA of incoming freshmen at NKU has been 2.32 at the end of their first year. With recent changes, the administration believes the mean GPA has increased. How would this be tested using a .05 level of significance? H0: The mean GPA is still 2.32. m = 2.32 Ha: The mean GPA is above 2.32. m > 2.32 The decision rule is to accept Ha if the p-value is less than .05. The test statistic is

  23. Performing the Test of Hypothesis In order to perform an actual test of hypothesis, we must identify several things, ensure the procedure is valid, and draw conclusions without stopping at calculations. For chapter 7, we are focusing on testing hypotheses which deal with the population mean m under the three assumptions: The population standard deviation s is known A random sample is obtained from the population The sample size is “large”. (Sampling Distn of )

  24. Steps of the Test of Hypothesis for m with s Identify the null and alternative hypotheses Give the decision rule Identify the form of the test statistic and calculate it based on the sampled data. Verify the method is valid (n is at least 30 for now) Calculate the p-value based on the z-score and Ha Give an interpretation.

  25. Example from Page 227 #6 H0: m = $122,000 Ha: m < $122,000 Decision Rule: Accept Ha if the p-value < .05. This is valid since n = 40 is at least 30. P-value = probability a z-score is “less than” 2.19 = 0.5 + 0.486 = 0.986 At the .05 level of significance, there is insufficient evidence to conclude the mean price for all new homes in Florida is below $122,000.

  26. Possible Errors Realize, that a small p-value (or observed level of significance) suggests that the alternative hypothesis is true, but does not guarantee it is true. A Type I Error consists of concluding that the alternative hypothesis is true when, in fact, the null hypothesis is true. A Type II Error consists of concluding that the null hypothesis is true when, in fact, the alternative hypothesis is true.

  27. Type I or Type II Errors We can examine each error and attempt to control how willing we are to commit each. The probability of committing a Type I Error is given by a(alpha), the level of significance of the test. The probability of committing a Type II Error is given by b (beta). We will decide the seriousness of each error, and then determine relative values for a and b.

  28. Type I or Type II Errors: #3 on page 234 H0: Lab is not contaminated with mercury vapor. Ha: Lab is contaminated with mercury vapor. A Type I Error occurs if we conclude the lab is contaminated when, in fact, the lab is not contaminated with mercury vapor. Consequences: The office would probably be closed, and procedures to reduce the mercury vapor levels would be implemented. This means costs for decontamination and lack of income from patients, but no one is endangered.

  29. Type I or Type II Errors: #3 on page 234 H0: Lab is not contaminated with mercury vapor. Ha: Lab is contaminated with mercury vapor. A Type II Error occurs if we conclude the lab is NOT contaminated when, in fact, the lab is contaminated with mercury vapor. Consequences: The office would be open and new patients and workers could be exposed to high levels of mercury vapor. This means possible law suits, people getting sick, dangerous work environment. It could lead to a bad reputation for this dental office.

  30. Type I or Type II Errors: #3 on page 234 H0: Lab is not contaminated with mercury vapor. Ha: Lab is contaminated with mercury vapor. Which error is worse? Probably Type II in my opinion. Hence, I want to avoid this, so I set the probability low. The Type I Error means a loss of income, so it’s not good for business, but it’s not as serious. I’d set a > b. I’d like b small at .01, and a maybe at .05.

  31. Type I or Type II Errors Be able to define a Type I Error and a Type II error in terms of a scenario. Be able to discuss the consequences of each type of error. Set values for a and b depending on those consequences. There are no rules on one error being worse than the other in all situations.

More Related