IENG 486 Lecture 06 Hypothesis Testing Excel Lab
IENG 486 - Lecture 06 Hypothesis Testing & Excel Lab 11/27/2020 IENG 486 Statistical Quality & Process Control 1
Assignment: w Preparation: n n Print Hypothesis Test Tables from Materials page Have this available in class …or exam! w Reading: n Chapter 4: l 4. 1. 1 through 4. 3. 4; (skip 4. 3. 5); 4. 3. 6 through 4. 4. 3; (skip rest) w HW 2: n CH 4: # 1 a, b; 5 a, c; 9 a, c, f; 11 a, b, d, g; 17 a, b; 18, 21 a, c; 22* *uses Fig. 4. 7, p. 126 11/27/2020 IENG 486 Statistical Quality & Process Control 2
Relationship with Hypothesis Tests w Assuming that our process is Normally Distributed and centered at the mean, how far apart should our specification limits be to obtain 99. 5% yield? n Proportion defective will be 1 –. 995 =. 005, and if the process is centered, half of those defectives will occur on the right tail (. 0025), and half on the left tail. n To get 1 –. 0025 = 99. 75% yield before the right tail requires the upper specification limit to be set at + 2. 81. 11/27/2020 TM 720: Statistical Process Control 3
11/27/2020 TM 720: Statistical Process Control 4
Relationship with Hypothesis Tests w Assuming that our process is Normally Distributed and centered at the mean, how far apart should our specification limits be to obtain 99. 5% yield? n Proportion defective will be 1 –. 995 =. 005, and if the process is centered, half of those defectives will occur on the right tail (. 0025), and half on the left tail. n n n To get 1 –. 0025 = 99. 75% yield before the right tail requires the upper specification limit to be set at + 2. 81. By symmetry, the remaining. 25% defective should occur at the left side, with the lower specification limit set at – 2. 81 If we specify our process in this manner and made a lot of parts, we would only produce bad parts. 5% of the time. 11/27/2020 IENG 486 Statistical Quality & Process Control 5
Hypothesis Tests w An Hypothesis is a guess about a situation, that can be tested and can be either true or false. n The Null Hypothesis has a symbol H , and is 0 always the default situation that must be proven wrong beyond a reasonable doubt. n The Alternative Hypothesis is denoted by the symbol HA and can be thought of as the opposite of the Null Hypothesis - it can also be either true or false, but it is always false when H 0 is true and vice -versa. 11/27/2020 IENG 486 Statistical Quality & Process Control 6
Hypothesis Testing Errors n Type I Errors occur when a test statistic leads us to reject the Null Hypothesis when the Null Hypothesis is true in reality. l The chance of making a Type I Error is estimated by the parameter (or level of significance), which quantifies the reasonable doubt. n Type II Errors occur when a test statistic leads us to fail to reject the Null Hypothesis when the Null Hypothesis is actually false in reality. l The probability of making a Type II Error is estimated by the parameter . 11/27/2020 IENG 486 Statistical Quality & Process Control 7
Testing Example w Single Sample, Two-Sided t-Test: n H 0: µ = µ 0 versus HA: µ ¹ µ 0 n Test Statistic: n Critical Region: reject H 0 if |t| > t /2, n-1 n P-Value: 2 x P(X ³ |t|), where the random variable X has a t-distribution with n _ 1 degrees of freedom 11/27/2020 IENG 486 Statistical Quality & Process Control 8
Hypothesis Testing H 0: = 0 versus HA: 0 P-value = P(X£-|t|) + P(X³|t|) tn-1 distribution Critical Region: if our test statistic value falls into the region (shown in orange), we reject H 0 and accept HA -|t| 11/27/2020 0 IENG 486 Statistical Quality & Process Control |t| 9
Types of Hypothesis Tests & Rejection Criteria θ θ 0 0 One-Sided Test Statistic < Rejection Criterion H 0 : θ ≥ θ 0 H A: θ < θ 0 11/27/2020 2 2 θ θ 0 0 θ Two-Sided Test Statistic < -½ Rejection Criterion or Statistic > +½ Rejection Criterion 0 θ One-Sided Test Statistic > Rejection Criterion H 0 : θ = θ 0 H A: θ ≠ θ 0 IENG 486 Statistical Quality & Process Control H 0 : θ ≤ θ 0 H A: θ > θ 0 10
Hypothesis Testing Steps 1. State the null hypothesis (H 0) from one of the alternatives: that the test statistic = 0 , ≥ 0 , or ≤ 0. 2. Choose the alternative hypothesis (HA) from the alternatives: 0 , < 0 , or > 0. (Respectively!) w Choose a significance level of the test ( ). w Select the appropriate test statistic and establish a critical region ( 0). (If the decision is to be based on a P-value, it is not necessary to have a critical region) w Compute the value of the test statistic ( ) from the sample data. w Decision: Reject H 0 if the test statistic has a value in the critical region (or if the computed P-value is less than or equal to the desired significance level ); otherwise, do not reject H 0. 11/27/2020 IENG 486 Statistical Quality & Process Control 11
Hypothesis Testing w Significance Level of a Hypothesis Test: A hypothesis test with a significance level or size rejects the null hypothesis H 0 if a p-value smaller than is obtained, and accepts the null hypothesis H 0 if a p-value larger than is obtained. In this case, the probability of a Type I error (the probability of rejecting the null hypothesis when it is true) is equal to . Test Conclusion True Situation 11/27/2020 H 0 is True H 0 is False H 0 is True CORRECT Type II Error ( ) H 0 is False Type I Error ( ) CORRECT IENG 486 Statistical Quality & Process Control 12
Hypothesis Testing w P-Value: One way to think of the P-value for a particular H 0 is: given the observed data set, what is the probability of obtaining this data set or worse when the null hypothesis is true. A “worse” data set is one which is less similar to the distribution for the null hypothesis. P-Value 0 0. 01 H 0 not plausible 11/27/2020 1 0. 10 Intermediate area H 0 plausible IENG 486 Statistical Quality & Process Control 13
Statistics and Sampling w Objective of statistical inference: n Draw conclusions/make decisions about a population based on a sample selected from the population w Random sample – a sample, x 1, x 2, …, xn , selected so that observations are independently and identically distributed (iid). w Statistic – function of the sample data n Quantities computed from observations in sample and used to make statistical inferences n e. g. measures central tendency 11/27/2020 IENG 486 Statistical Quality & Process Control 14
Sampling Distribution w Sampling Distribution – Probability distribution of a statistic w If we know the distribution of the population from which sample was taken, n we can often determine the distribution of various statistics computed from a sample 11/27/2020 IENG 486 Statistical Quality & Process Control 15
e. g. Sampling Distribution of the Average from the Normal Distribution w Take a random sample, x 1, x 2, …, xn, from a normal population with mean and standard deviation , i. e. , w Compute the sample average w Then will be normally distributed with mean and std deviation w That is 11/27/2020 IENG 486 Statistical Quality & Process Control 16
Ex. Sampling Distribution of x w When a process is operating properly, the mean density of a liquid is 10 with standard deviation 5. Five observations are taken and the average density is 15. w What is the distribution of the sample average? n r. v. x = density of liquid Ans: since the samples come from a normal distribution, and are added together in the process of computing the mean: 11/27/2020 IENG 486 Statistical Quality & Process Control 17
Ex. Sampling Distribution of x (cont'd) w What is the probability the sample average is greater than 15? w Would you conclude the process is operating properly? 11/27/2020 IENG 486 Statistical Quality & Process Control 18
11/27/2020 IENG 486 Statistical Quality & Process Control 19
Ex. Sampling Distribution of x (cont'd) w What is the probability the sample average is greater than 15? w Would you conclude the process is operating properly? 11/27/2020 IENG 486 Statistical Quality & Process Control 20
- Slides: 20