20
Chapter 9: Tests of Hypotheses for a Single Sample 9-1 Hypothesis Testing 9 - 3.2 Type II Error & Choice of Sample 9-1.1 Statistical Hypotheses 9-1.2 Tests of Statistical Hypotheses 9-1.3 1-Sided & 2-Sided Hypotheses Size 9-4 Tests of the Variance & Standard Deviation of a Normal Distribution. 9-1.4 P-Values in Hypothesis Tests 9-1.5 Connection between Hypothesis Tests & Confidence Intervals 9-4.1 Hypothesis Test on the Variance 9 - 4.2 Type II Error & Choice of Sample Size 9-1.6 General Procedures for Hypothesis Tests 9-2 Tests on the Mean of a Normal 9-5 Tests on a Population Proportion 9-5.1 Large-Sample Test on a Proportion 9-5.2 Type II Error & Choice of Sample Si Distribution, Variance Known 9-2.1 Hypothesis Tests on the Mean 9-2.2 Type II Error & Choice of Sample Size 9-6 Summary Table of Inference Procedures for a Single Sample 9 7 Testing for Goodness of Fit Size 9-2.3 Large-Sample Test 9-3 Tests on the Mean of a Normal 9-7 Testing for Goodness of Fit 9 - 8 Contingency Table Tests 9 - 9 Non - Parametric Procedures 9 9 1 Si T t Distribution, Variance Unknown 9-3.1 Hypothesis Tests on the Mean 9 - 9.1 Sign Test 9 - 9.2 Wilcoxen Signed - Rank Test 9 - 9.3 Comparison to the t - test 1 Chapter Learning Objectives After careful study of this chapter you should be able to: 1 Structure engineering decision-making as hypothesis tests 1. Structure engineering decision-making as hypothesis tests 2. Test hypotheses on the mean of a normal distribution using either a Z- test or a t-test procedure 3 Test hypotheses on the variance or standard deviation of a normal 3. Test hypotheses on the variance or standard deviation of a normal distribution 4. Test hypotheses on a population proportion 5 Use the P-value approach for making decisions in hypothesis tests 5. Use the P value approach for making decisions in hypothesis tests 6. Compute power & Type II error probability. Make sample size selection decisions for tests on means, variances & proportions 7 Explain & use the relationship between confidence intervals & 7. Explain & use the relationship between confidence intervals & hypothesis tests 8. Use the chi-square goodness-of-fit test to check distributional assumptions 9. Use contingency table tests 2 Introduction Introduction Statistical hypothesis testing and confidence interval estimation of parameters are the fundamentalmethods used at the data analysis stage of a comparative experiment, in which the engineer is interested, for example, in comparing the mean of a population to a specified value. Definition: 3 Hypothesis Testing Example F l th t it td i th Hypothesis Testing - Example For example, suppose that we are interested in the burning rate of a solid propellant used to power aircrew t escape systems. • Burning rate is a random variable that can be described by a probability distribution. S th t it t f th b i Suppose that our interest focuses on the mean burning rate (a parameter of this distribution). • Specifically, we are interested in deciding whether or not the mean burning rate is 50 centimeters per second. 4

Introduction for a Single Sample Chapter 9: Tests of ...roneducate.weebly.com/uploads/6/2/3/8/6238184/chap...Testing confidence n intervals & hypothesis tests 8. Use the chi-square

  • Upload
    others

  • View
    6

  • Download
    0

Embed Size (px)

Citation preview

Page 1: Introduction for a Single Sample Chapter 9: Tests of ...roneducate.weebly.com/uploads/6/2/3/8/6238184/chap...Testing confidence n intervals & hypothesis tests 8. Use the chi-square

Chapter 9: Tests of Hypotheses for a Single Sample

9-1 Hypothesis Testing 9-3.2 Type II Error & Choice of Sample yp g9-1.1 Statistical Hypotheses9-1.2 Tests of Statistical Hypotheses9-1.3 1-Sided & 2-Sided Hypotheses

Size9-4 Tests of the Variance & Standard

Deviation of a Normal Distribution.yp9-1.4 P-Values in Hypothesis Tests9-1.5 Connection between Hypothesis Tests & Confidence Intervals

9-4.1 Hypothesis Test on the Variance9-4.2 Type II Error & Choice of Sample Size

9-1.6 General Procedures for Hypothesis Tests

9-2 Tests on the Mean of a Normal

9-5 Tests on a Population Proportion9-5.1 Large-Sample Test on a Proportion9-5.2 Type II Error & Choice of Sample SiDistribution, Variance Known

9-2.1 Hypothesis Tests on the Mean9-2.2 Type II Error & Choice of Sample

Size 9-6 Summary Table of Inference Procedures

for a Single Sample9 7 Testing for Goodness of FitSize

9-2.3 Large-Sample Test9-3 Tests on the Mean of a Normal

9-7 Testing for Goodness of Fit9-8 Contingency Table Tests9-9 Non-Parametric Procedures

9 9 1 Si T tDistribution, Variance Unknown9-3.1 Hypothesis Tests on the Mean

9-9.1 Sign Test9-9.2 Wilcoxen Signed-Rank Test9-9.3 Comparison to the t-test 1

Chapter Learning ObjectivesAfter careful study of this chapter you should be able to:

1 Structure engineering decision-making as hypothesis tests1. Structure engineering decision-making as hypothesis tests2. Test hypotheses on the mean of a normal distribution using either a Z-

test or a t-test procedure3 Test hypotheses on the variance or standard deviation of a normal3. Test hypotheses on the variance or standard deviation of a normal

distribution4. Test hypotheses on a population proportion5 Use the P-value approach for making decisions in hypothesis tests5. Use the P value approach for making decisions in hypothesis tests6. Compute power & Type II error probability. Make sample size

selection decisions for tests on means, variances & proportions7 Explain & use the relationship between confidence intervals &7. Explain & use the relationship between confidence intervals &

hypothesis tests8. Use the chi-square goodness-of-fit test to check distributional

assumptionsp9. Use contingency table tests

2

IntroductionIntroduction

Statistical hypothesis testing and confidence intervalestimation of parameters are the fundamental methodsest at o o pa a ete s a e t e u da e ta et odsused at the data analysis stage of a comparativeexperiment, in which the engineer is interested, forp , g ,example, in comparing the mean of a population to aspecified value.

Definition:

p

3

Hypothesis Testing ExampleF l th t i t t d i th

Hypothesis Testing - ExampleFor example, suppose that we are interested in theburning rate of a solid propellant used to power aircrew

tescape systems.

• Burning rate is a random variable that can be describedgby a probability distribution.

S th t i t t f th b i• Suppose that our interest focuses on the mean burningrate (a parameter of this distribution).

• Specifically, we are interested in deciding whether ornot the mean burning rate is 50 centimeters per second.g p

4

Page 2: Introduction for a Single Sample Chapter 9: Tests of ...roneducate.weebly.com/uploads/6/2/3/8/6238184/chap...Testing confidence n intervals & hypothesis tests 8. Use the chi-square

Types of Hypotheses ExampleTypes of Hypotheses - Example

ll h th iTwo-sided Alternative Hypothesis

null hypothesis

alternative hypothesisyp

One sided Alternative HypothesesOne-sided Alternative Hypotheses

5

Test of a Hypothesis• A test of a hypothesis is a procedure leading to a

Test of a Hypothesis• A test of a hypothesis is a procedure leading to a

decision about a particular hypothesis.

• Hypothesis-testing relies on using the information in a random sample from the population of interestrandom sample from the population of interest.

• If this information is consistent with the hypothesis we• If this information is consistent with the hypothesis, we conclude that the hypothesis cannot be rejected (it is quite possibly true) If this information is inconsistentquite possibly true). If this information is inconsistentwith the hypothesis, we conclude that the hypothesis should be rejected (it is quite possibly false)should be rejected (it is quite possibly false).

6

Hypothesis Decision CriteriaHypothesis Decision Criteria

Figure 9-1: Decision criteria for testing H0:� = 50 centimeters per second versus H :� � 50 centimeters per secondper second versus H1:� � 50 centimeters per second.

7

Type I and II ErrorType I and II ErrorType I and Type II errors relate to making incorrectType I and Type II errors relate to making incorrect conclusions based on our sample information.Obviously we’d like to reduce such errors but eliminating them is not possible due to the uncertainty associated with sampling information.

8

Page 3: Introduction for a Single Sample Chapter 9: Tests of ...roneducate.weebly.com/uploads/6/2/3/8/6238184/chap...Testing confidence n intervals & hypothesis tests 8. Use the chi-square

Decisions of Hypothesis TestingDecisions of Hypothesis Testing

9

Probability of Type I & II ErrorProbability of Type I & II Error

Sometimes the Type I error probability is called the significance level, or the �-error, or the size of the test.

Sometimes the Type II error probability is called the �-Sometimes the Type II error probability is called the �error.

10

Type I Probability (�=50 n=10)Type I Probability (�=50, n=10)Assume the burning rate example with a mean of 50, standard g p ,deviation of 2.5, and a sample size of 10.

Using Equation 8 2 we can determine � as follows:Using Equation 8.2, we can determine � as follows:

11

Cumulative Standard Normal Distribution

z �0.09 �0.08 �0.07 �0.06 �0.05 �0.04 �0.03 �0.02 �0.01 �0.00

�2.4 0.006387 0.006569 0.006756 0.006947 0.007143 0.007344 0.007549 0.007760 0.007976 0.0081982 3 0 008424 0 008656 0 008894 0 009137 0 009387 0 009642 0 009903 0 010170 0 010444 0 010724�2.3 0.008424 0.008656 0.008894 0.009137 0.009387 0.009642 0.009903 0.010170 0.010444 0.010724

�2.2 0.011011 0.011304 0.011604 0.011911 0.012224 0.012545 0.012874 0.013209 0.013553 0.013903�2.1 0.014262 0.014629 0.015003 0.015386 0.015778 0.016177 0.016586 0.017003 0.017429 0.017864�2.0 0.018309 0.018763 0.019226 0.019699 0.020182 0.020675 0.021178 0.021692 0.022216 0.022750�1.9 0.023295 0.023852 0.024419 0.024998 0.025588 0.026190 0.026803 0.027429 0.028067 0.028717�1.8 0.029379 0.030054 0.030742 0.031443 0.032157 0.032884 0.033625 0.034379 0.035148 0.035930�1.7 0.036727 0.037538 0.038364 0.039204 0.040059 0.040929 0.041815 0.042716 0.043633 0.044565

1 6 0 045514 0 046479 0 047460 0 048457 0 049471 0 050503 0 051551 0 052616 0 053699 0 054799�1.6 0.045514 0.046479 0.047460 0.048457 0.049471 0.050503 0.051551 0.052616 0.053699 0.054799

From Table III page 708 in Montgomery and Runger Ed 5From Table III, page 708 in Montgomery and Runger, Ed. 5

12

Page 4: Introduction for a Single Sample Chapter 9: Tests of ...roneducate.weebly.com/uploads/6/2/3/8/6238184/chap...Testing confidence n intervals & hypothesis tests 8. Use the chi-square

Decreasing the probability of Type I error can be achieved by:

• Increasing the interval (i.e. currently is 48.5 to 51.5)

13

• Increasing n (i.e. this will tighten the distribution)

Type II Probability (�=52 n=10)Type II Probability (�=52, n=10)

14

Figure 9-3: The probability of Type II error when 52 and nerror when � = 52 and n= 10.

15

Type II Probability (�=50 5 n=10)Type II Probability (�=50.5, n=10)

16

Page 5: Introduction for a Single Sample Chapter 9: Tests of ...roneducate.weebly.com/uploads/6/2/3/8/6238184/chap...Testing confidence n intervals & hypothesis tests 8. Use the chi-square

Figure 9 4: TheFigure 9-4: Theprobability of type II error when � = 50.5 �and n = 10.

Comparing with Fig. 9.3 (� = 52), we see that �increases as � becomes closer to �0.

17

� �0

Type II Probability (�=52 n=16)Type II Probability (�=52, n=16)

18

Figure 9-5 :The probability of type II

h 52 derror when � = 52 and n= 16.

Comparing with Fig. 9.3 (� = 52, n = 10), we see that �decreases as n increases.

19

P f St ti ti l T tPower of a Statistical Test

• The power is computed as 1 - �, and power can be interpreted as the probability of correctly rejecting a false null hypothesis.p y f y j g f ypWe often compare statistical tests by comparing their power properties.

• For example, consider the propellant burning rate problem when we are testing H 0 : � = 50 centimeters per second against H 1 : � not equal 50 centimeters per second . Suppose that the true mean is � = 52. When n = 10, we found that � = 0 2643 so the power of this test is 1 � = 1 0 2643 = 0 73570.2643, so the power of this test is 1 - � = 1 - 0.2643 = 0.7357 when � = 52.

20

Page 6: Introduction for a Single Sample Chapter 9: Tests of ...roneducate.weebly.com/uploads/6/2/3/8/6238184/chap...Testing confidence n intervals & hypothesis tests 8. Use the chi-square

O d T Sid d H thOne and Two-Sided Hypotheses Two-Sided Test:

One-Sided Tests:

21

One and Two-Sided Hypothesis -One and Two Sided Hypothesis Burn Rate Example

Example 9-1

22

Alt t H th i ITh b ttl t t b th t th b ttl t th

Alternate Hypothesis IssueThe bottler wants to be sure that the bottles meet thespecification on mean internal pressure or burstingt th hi h f 10 b ttl i i istrength, which for 10-ounce bottles is a minimum

strength of 200 psi. The bottler has decided to formulateth d i i d f ifi l t f b ttlthe decision procedure for a specific lot of bottles as ahypothesis testing problem. There are two possiblef l ti f thi bl ithformulations for this problem, either:

or

23

P l i H th i T tP-values in Hypothesis Tests

Definition:

24

Page 7: Introduction for a Single Sample Chapter 9: Tests of ...roneducate.weebly.com/uploads/6/2/3/8/6238184/chap...Testing confidence n intervals & hypothesis tests 8. Use the chi-square

P l B R t E lP-values – Burn Rate Example

25

P l B R t Ill t tiP-values – Burn Rate Illustration

26

Connection Between HypothesisypTests and Confidence Intervals

8 118-11

27

General Procedure for Hypothesis Tests

1. From the problem context, identify the parameter of interest.2. State the null hypothesis, H0 .yp , 0

3. Specify an appropriate alternative hypothesis, H1.4. Determine an appropriate test statistic.4. Determine an appropriate test statistic.5. State the rejection criteria (region and �) for the statistic.6 Compute any necessary sample quantities substitute these into6. Compute any necessary sample quantities, substitute these into

the equation for the test statistic, and compute that value.7. Decide whether or not H0 should be rejected and draw0 j

conclusions in the problem context.

28

Page 8: Introduction for a Single Sample Chapter 9: Tests of ...roneducate.weebly.com/uploads/6/2/3/8/6238184/chap...Testing confidence n intervals & hypothesis tests 8. Use the chi-square

Two-Sided Hypothesis Rejection RulesFor H0: � = �0 and H1: � = �0, use the test statistic:

Reject H0 if the observed value of the test statistic z0 is i heither:

z0 > z�/2 or z0 < -z�/2

Fail to reject H0 if :-z /2 < z0 < z /2z�/2 < z0 < z�/2

29

Two-Sided Hypothesis Evaluation –Two Sided Hypothesis Evaluation Burning Rate Example

Example 9-2

30

Example 9-2 (continued)We may solve this problem using the seven-step procedure in Section 9-1.6:

1 Parameter of interest is � the mean burning rate1. Parameter of interest is �, the mean burning rate.2. H0: � = 50 centimetres per second.3. H1: � � 50 centimetres per second.4. Test statistic is:. es s s c s:

xz �00

��

5. Reject H0 if the P-value is less than 0.05. To use a fixed significance level test, the boundaries of the critical region would be z0.025 = 1.96 and

n�0

-z0.025 = -1.96.6. Compute:

25.3503.510 �

��z

7. Conclude: Since 3.25 is greater than 1.96, reject H0 at the 0.05 level of i ifi Th l i 0 0012

2520

31

significance. The p-value is 0.0012.

Critical Regions for One & Two SidedCritical Regions for One & Two-Sided Hypothesis Tests – Variances Knownyp

9-8

32

Page 9: Introduction for a Single Sample Chapter 9: Tests of ...roneducate.weebly.com/uploads/6/2/3/8/6238184/chap...Testing confidence n intervals & hypothesis tests 8. Use the chi-square

One Sided Hypothesis Tests on MeanOne-Sided Hypothesis Tests on Mean of Normal Dist., Variance Known,

Upper-tail tests:

(9-10)

(9-17)

33

(9 17)

Lower tail tests:Lower -tail tests:

(9-12)( )

(9-18)( )

34

Summary of Tests on Mean of NormalSummary of Tests on Mean of Normal Distribution, Variance Known,

35

Summary of P Values for Mean ofSummary of P-Values for Mean of Normal Distribution, Variance Known,

Recall that �(z0) = P(Z � z0), where Z is N(0,1). It is the standard normal cumulative distribution function.

36

Page 10: Introduction for a Single Sample Chapter 9: Tests of ...roneducate.weebly.com/uploads/6/2/3/8/6238184/chap...Testing confidence n intervals & hypothesis tests 8. Use the chi-square

Finding the Probability ofFinding the Probability of Type II Error, �yp , �

(9-19)

37

( )

D i i � h i � f dDetermining � when true mean is � from assumed �:

(9-20)

Figure 9-9: The distribution of Z0 under H0 and H138

Adequate Sample SizesFor a two-sided alternative hypothesis:

Adequate Sample Sizes yp

(9-22)

For a one-sided alternative hypothesis:

(9-23)

Note that z is associated with Type I error and z� is associatedNote that z� is associated with Type I error and z� is associated with the Type II error:

39

Ad t S l Si E lAdequate Sample Size - ExampleExample 9-3

40

Page 11: Introduction for a Single Sample Chapter 9: Tests of ...roneducate.weebly.com/uploads/6/2/3/8/6238184/chap...Testing confidence n intervals & hypothesis tests 8. Use the chi-square

Operating Curves for Type II Error andOperating Curves for Type II Error and Adequate Sample Size Calculationsq p

VIIa and b. 9-209 20

(9-24)

41

9 209-209-9

42

OC Curve for Two Sided Test � = 0 05OC Curve for Two-Sided Test, � = 0.05

Appendix A, Chart VIIa, Montgomery and Runger, Ed. 5, p. 71743

OC Curve for Two Sided Test � = 0 01OC Curve for Two-Sided Test, � = 0.01

Appendix A, Chart VIIb, Montgomery and Runger, Ed. 5, p. 71744

Page 12: Introduction for a Single Sample Chapter 9: Tests of ...roneducate.weebly.com/uploads/6/2/3/8/6238184/chap...Testing confidence n intervals & hypothesis tests 8. Use the chi-square

Determining Type II Error using g yp gOperating Curves - Example

Example 9-4

9-24 gives

45

L S l T tLarge Sample Tests

The concept of treating a large-sample variance as a knownvariance applies to both confidence interval construction andh h i ihypothesis testing.

46

Hypothesis Tests for the Mean of a ypNormal Distribution, Var. Unknown

One-Sample t-Test

47

Critical Regions for One & Two SidedCritical Regions for One & Two-Sided Hypothesis Tests –Variances Unknownyp

Figure 9-12: The reference distribution for H0: � = �0 with critical region for (a) H1: � � �0 , (b) H1: � > �0, and (c) H1: � < �0.

48

Page 13: Introduction for a Single Sample Chapter 9: Tests of ...roneducate.weebly.com/uploads/6/2/3/8/6238184/chap...Testing confidence n intervals & hypothesis tests 8. Use the chi-square

Test for the Mean of a Normal Distribution, Var. Unknown - ExampleExample 9-6

49

Example 9-6 (continued)Using the seven-step procedure for hypothesis testing:

f i i h ffi i f i i

p ( )

1. Parameter of interest is �, the coefficient of restitution.2. H0: � = 0.82.3. H1: � > 0.82.4 T t t ti ti i4. Test statistic is:

nsxt 0

0��

5. Reject H0 if the P-value is less than 0.05. In this case t0 must be greater than t�,n-1 = t0.05,14 = 1.761.

6. Compute:72.2

1502456.082.083725/0

0 ��

�t

7. Conclude: Since 2.72 > 1.761 (the critical value of t) we reject the H0 at the 95% confidence level and conclude the mean coefficient of restitution

50exceeds 0.82.

Example 9-6 (continued)Example 9 6 (continued)In addition, the assumption that the coefficient of restitution isnormally distributed should be checked The following normalnormally distributed should be checked. The following normalprobability plot supports this assumption.

Figure 9-13: Normal probabilityNormal probability plot of the coefficient of restitution data

51

P value for a t testP-value for a t-test

The P-value for a t-test is the smallest level of significance at which the null hypothesis would be rejected.

Notice that t0 = 2.72 in Example 9-6, and that this is between two t b l t d l 2 624 d 2 977 Th f th P l t btabulated values, 2.624 and 2.977. Therefore, the P-value must be between 0.01 and 0.005. These are effectively the upper and lower bounds on the P-value.bounds on the P value.

52

Page 14: Introduction for a Single Sample Chapter 9: Tests of ...roneducate.weebly.com/uploads/6/2/3/8/6238184/chap...Testing confidence n intervals & hypothesis tests 8. Use the chi-square

Tests on Variance of a Normal PopulationHypothesis Test on the Variance – Two-Tailed

Tests on Variance of a Normal PopulationHypothesis Test on the Variance Two Tailed

(9-34)

(9-35)

53

Chi-Squared Test Statistic – Two-tailed testChi Squared Test Statistic Two tailed test

9-35

4

54

Hypothesis Test on the Variance – One-TailedHypothesis Test on the Variance One Tailed

(9-36)

(9-37)

4

55

4

Chi-squared Critical Regions – One and Two-TailedChi squared Critical Regions One and Two Tailed

9-14

56

Page 15: Introduction for a Single Sample Chapter 9: Tests of ...roneducate.weebly.com/uploads/6/2/3/8/6238184/chap...Testing confidence n intervals & hypothesis tests 8. Use the chi-square

Example 9 8 (One tailed test)Example 9-8 (One-tailed test)

57

Example 9-8 (continued)p ( )Using the seven-step procedure for hypothesis testing:

f i i 2 h l i i1. Parameter of interest is �2, the population variance.2. H0: �2 = 0.01.3. H1: �2 > 0.01.4 T t t ti ti i4. Test statistic is:

20

220

1�

� sn ��

5. Reject H0 if

6 Compute:

14.30219,05.0

20 �� ��

6. Compute:

07.2901.00153.0192

0 ���

7. Conclude: Since 29.07<30.14, we cannot conclude at the 95% confidence level that the variance exceeds 0.01. Therefore, strong evidence that bottles are being filled incorrectly is lacking.

58

g y g

Percentage Pointsof the Chi-Squared DistributionPercentage Pointsof the Chi Squared Distribution

�\� 1.00 0.99 0.98 0.95 0.90 0.50 0.10 0.05 0.03 0.01 0.01

15 4 60 5 23 6 27 7 26 8 55 14 34 22 31 25 00 27 49 30 58 32 80 15 4.60 5.23 6.27 7.26 8.55 14.34 22.31 25.00 27.49 30.58 32.80 16 5.14 5.81 6.91 7.96 9.31 15.34 23.54 26.30 28.85 32.00 34.27 17 5.70 6.41 7.56 8.67 10.09 16.34 24.77 27.59 30.19 33.41 35.72 18 6.26 7.01 8.23 9.39 10.87 17.34 25.99 28.87 31.53 34.81 37.16 19 6.84 7.63 8.91 10.12 11.65 18.34 27.20 30.14 32.85 36.19 38.58 20 7.43 8.26 9.59 10.85 12.44 19.34 28.41 31.41 34.17 37.57 40.00 21 8.03 8.90 10.28 11.59 13.24 20.34 29.62 32.67 35.48 38.93 41.40 22 8.64 9.54 10.98 12.34 14.04 21.34 30.81 33.92 36.78 40.29 42.80 23 9.26 10.20 11.69 13.09 14.85 22.34 32.01 35.17 38.08 41.64 44.18 24 9.89 10.86 12.40 13.85 15.66 23.34 33.20 36.42 39.36 42.98 45.56 25 10.52 11.52 13.12 14.61 16.47 24.34 34.28 37.65 40.65 44.31 46.93

59

L S l T t P tiLarge-Sample Tests on a ProportionM i i d i i bl i l d h th i t tiMany engineering decision problems include hypothesis testing about p.

An appropriate test statistic is:An appropriate test statistic is:

(9-40)

60

Page 16: Introduction for a Single Sample Chapter 9: Tests of ...roneducate.weebly.com/uploads/6/2/3/8/6238184/chap...Testing confidence n intervals & hypothesis tests 8. Use the chi-square

Alt t f f th t t t ti ti ZAlternate forms of the test statistic Z0 are:

or

Critical regions for the one and two sided tests are:

Alternative hypothesis Rejection criteria

Critical regions for the one and two sided tests are:

H1: p � p0 z0 > z�/2 or z0 < z�/2H1: p > p0 z0 > z�H : p < p z < zH1: p < p0 z0 < z�

61

L S l P ti E lExample 9-10

Large-Sample Proportion - ExampleExample 9 10

62

Example 9-10 (continued)p ( )Using the seven-step procedure for hypothesis testing:

f i i h f i d f i1. Parameter of interest is the process fraction defective, p.2. H0: p = 0.05.3. H1: p < 0.05.4 T t t ti ti i4. Test statistic is:

00

00 1 pnp

npxz�

��

5. Reject H0 if p-value < 0.05 or if 6. Compute:

0502004 �

645.10 ��� �zz

95.195.005.0200

05.020040 ��

��z

7. Conclude: Since the p-value associated with z0 = -1.95 is 0.0256, which is < 0.05, we conclude the process defective is < 0.05. Alternately, we

63

, p y,can reach the same conclusion by noting z0 < -1.645.

P ti T II EProportion Type II ErrorFor a two-sided alternative

If the alternative is p < p

(9-42)

If the alternative is p < p0

(9-43)

If the alternative is p > p0

(9 43)

p p0

(9-44)

64

( )

Page 17: Introduction for a Single Sample Chapter 9: Tests of ...roneducate.weebly.com/uploads/6/2/3/8/6238184/chap...Testing confidence n intervals & hypothesis tests 8. Use the chi-square

P ti S l SiProportion Sample Size

For a two-sided alternative

(9-45)

For a one-sided alternativeFor a one sided alternative

(9-46)

65

P l ti P ti E lExample 9-11

Population Proportion - ExampleExample 9 11

9-43

66

Example 9-11 (Continued)Example 9 11 (Continued)

(9 46)(9-46)

67

8-1

8-1.5

8-2

8-3

8-4

68

Page 18: Introduction for a Single Sample Chapter 9: Tests of ...roneducate.weebly.com/uploads/6/2/3/8/6238184/chap...Testing confidence n intervals & hypothesis tests 8. Use the chi-square

Testing for Goodness of FitTesting for Goodness of FitUntil now we have been dealing with problems where theUntil now we have been dealing with problems where the distribution is known. Hypothesis testing then involves the parameters of this distribution.

Another type of hypothesis testing can be applied when the underlying distribution of the population is unknown but we y g p pwish to hypothesize that it follows a certain distribution.

Recall that for the normal distribution we have examined usingRecall that for the normal distribution we have examined using normal probability plots to determine if the population is normal.

We now examine a formal goodness-of-fit test based on the chi-squared distribution.

69

q

The chi squared test procedure:The chi-squared test procedure:• Take a random sample of size n from the unknown population.

A th b ti i k bi h lik f• Arrange these observations in k bins, much like a frequency histogram. Each bin should have 3 or more observations. These bins do not need to represent equal interval sizesThese bins do not need to represent equal interval sizes.

• Let Oi be the observed number of observations (frequency) in the ith bin.

• Let Ei be the expected number of observations (frequency) in the ith bin, based on the hypothesized distribution.yp

The goodness-of-fit test statistic is then given by the following.

70

If the population is distributed according to the hypothesized distribution � 2 will have a chi-squared distribution with k-p-1distribution �0 will have a chi-squared distribution, with k-p-1degrees of freedom.

Therefore, set up the hypotheses as follows:

H0 : The population has is distributed as hypothesizedH Th l i h i di ib d h h i dH1 : The population has is not distributed as hypothesized

j ifReject H0 if:2

1,20 ��� pk���

71

,0 pk�

Example�9�12�– Goodness�of�fit�testing

Page 19: Introduction for a Single Sample Chapter 9: Tests of ...roneducate.weebly.com/uploads/6/2/3/8/6238184/chap...Testing confidence n intervals & hypothesis tests 8. Use the chi-square

Example 9 12 continuedExample�9�12�– continued Example 9 12 continuedExample�9�12�– continued

Example 9 12 continuedExample�9�12�– continued Example 9 12 continuedExample�9�12�– continued

Page 20: Introduction for a Single Sample Chapter 9: Tests of ...roneducate.weebly.com/uploads/6/2/3/8/6238184/chap...Testing confidence n intervals & hypothesis tests 8. Use the chi-square

Example 9 12 continuedExample�9�12�– continued