62
1 Overview Definition Hypothesis in statistics, is a claim or statement about a property of a population

1 Overview Definition Hypothesis in statistics, is a claim or statement about a property of a population

Embed Size (px)

Citation preview

1

Overview

Definition

Hypothesis

in statistics, is a claim or statement about a property of a population

2

Null Hypothesis: H0

Statement about value of population parameter

Must contain condition of equality

=, , or

Test the Null Hypothesis directly

Reject H0 or fail to reject H0

3

Alternative Hypothesis: Ha

Must be true if H0 is false

, <, >

‘opposite’ of Null

4

Note about Forming Your Own Claims (Hypotheses)

If you are conducting a study and want to use a hypothesis test to support your claim, the claim must be worded so that it becomes the alternative hypothesis.

5

HO The defendant Claim about a is not guilty population parameter

HA The defendant Opposing claim about ais guilty population parameter

Result The evidence The statistic indicates aconvinces the rejection of HO, and thejury to reject alternate hypothesis isthe assumption accepted.of innocence. Theverdict is guilty

Legal Trial Hypothesis Test

6

Test Statistic

a value computed from the sample data that is used in making the decision about the

rejection of the null hypothesis

7

Test Statistic

a value computed from the sample data that is used in making the decision about the rejection of the null hypothesis

For large samples, testing claims about population means

z = x - µx

n

8

Critical RegionSet of all values of the test statistic that

would cause a rejection of the null hypothesis

9

Critical RegionSet of all values of the test statistic that

would cause a rejection of thenull hypothesis

CriticalRegion

10

Critical RegionSet of all values of the test statistic that

would cause a rejection of the null hypothesis

CriticalRegion

11

Critical RegionSet of all values of the test statistic that

would cause a rejection of the null hypothesis

CriticalRegions

12

Significance Level denoted by the probability that the

test statistic will fall in the critical region when the null hypothesis is actually true.

common choices are 0.05, 0.01, and 0.10

13

Critical ValueValue or values that separate the critical region

(where we reject the null hypothesis) from the values of the test statistics that do not lead

to a rejection of the null hypothesis

14

Critical Value

Critical Value( z score )

Value or values that separate the critical region (where we reject the null hypothesis) from the values of the test statistics that do not lead

to a rejection of the null hypothesis

15

Critical Value

Critical Value( z score )

Fail to reject H0Reject H0

Value or values that separate the critical region (where we reject the null hypothesis) from the values of the test statistics that do not lead

to a rejection of the null hypothesis

16

Two-tailed,Right-tailed,Left-tailed Tests

The tails in a distribution are the extreme regions bounded

by critical values.

17

Two-tailed TestH0: µ = 100

Ha: µ 100

18

Two-tailed TestH0: µ = 100

Ha: µ 100 is divided equally between

the two tails of the critical region

19

Two-tailed TestH0: µ = 100

Ha: µ 100

Means less than or greater than

is divided equally between the two tails of the critical

region

20

Two-tailed TestH0: µ = 100

Ha: µ 100

Means less than or greater than

100

Values that differ significantly from 100

is divided equally between the two tails of the critical

region

Fail to reject H0Reject H0 Reject H0

21

Right-tailed TestH0: µ 100

Ha: µ > 100

22

Right-tailed TestH0: µ 100

Ha: µ > 100

Points Right

23

Right-tailed TestH0: µ 100

Ha: µ > 100

Values that differ significantly

from 100100

Points Right

Fail to reject H0 Reject H0

24

Left-tailed Test

H0: µ 100

Ha: µ < 100

25

Left-tailed Test

H0: µ 100

Ha: µ < 100Points Left

26

Left-tailed Test

H0: µ 100

Ha: µ < 100

100

Values that differ significantly

from 100

Points Left

Fail to reject H0Reject H0

27

Conclusions in Hypothesis Testing

always test the null hypothesis

1. Reject the H0

2. Fail to reject the H0

need to formulate correct wording of final conclusion

28

Wording of Final Conclusion

Does theoriginal claim contain

the condition ofequality

Doyou reject

H0?.

Yes

(Original claim

contains equality

and becomes H0)

No(Original claimdoes not containequality and

becomes Ha)

Yes

(Reject H0)

“There is sufficientevidence to warrantrejection of the claimthat. . . (original claim).”

“There is not sufficientevidence to warrantrejection of the claimthat. . . (original claim).”

“The sample datasupports the claim that . . . (original claim).”

“There is not sufficientevidence to support the claimthat. . . (original claim).”

Doyou reject

H0?

Yes

(Reject H0)

No(Fail to

reject H0)

No(Fail to

reject H0)

(This is theonly case inwhich theoriginal claimis rejected).

(This is theonly case inwhich theoriginal claimis supported).

Start

29

Accept versus Fail to Reject

some texts use “accept the null hypothesis

we are not proving the null hypothesis

sample evidence is not strong enough to warrant rejection (such as not enough evidence to convict a suspect)

30

Definition

Power of a Hypothesis Test

is the probability (1 - ) of rejecting a false null hypothesis, which is computed by using a particular significance level and a particular value of the mean that is an alternative to the value assumed true in the null hypothesis.

31

Assumptionsfor testing claims about population means

1) The sample is a simple random       sample.

2) The sample is large (n > 30).

a) Central limit theorem applies

b) Can use normal distribution

3) If is unknown, we can use sample standard deviation s as estimate for .

32

Traditional (or Classical) Method of Testing Hypotheses

Goal

Identify a sample result that is significantly different from the claimed value

33

The traditional (or classical) method of hypothesis testing converts the relevant sample statistic into a test statistic which we compare to the

critical value.

34

1. State the hypotheses

2. Decide on a model.

3. Determine the endpoints of the rejection region and state the decision rule.

4. Compute the test statistic

5. State the conclusion

Hypotheses Testing5 Step Process

35

Test Statistic for Claims about µ when n > 30

n

x - µxz =

n

x - µxt =

Test Statistic for Claims about µ when n < 30

36

Decision Criterion

Reject the null hypothesis if the test statistic is in the critical region

Fail to reject the null hypothesis if the test statistic is not in the critical region

37

FIGURE 7-4 Wording of Final Conclusion

Does theoriginal claim contain

the condition ofequality

Doyou reject

H0?.

Yes

(Original claim

contains equality

and becomes H0)

No(Original claimdoes not containequality and

becomes Ha)

Yes

(Reject H0)

“There is sufficientevidence to warrantrejection of the claimthat. . . (original claim).”

“There is not sufficientevidence to warrantrejection of the claimthat. . . (original claim).”

“The sample datasupports the claim that . . . (original claim).”

“There is not sufficientevidence to support the claimthat. . . (original claim).”

Doyou reject

H0?

Yes

(Reject H0)

No(Fail to

reject H0)

No(Fail to

reject H0)

(This is theonly case inwhich theoriginal claimis rejected).

(This is theonly case inwhich theoriginal claimis supported).

Start

38

Example: Given a data set of 106 healthy body temperatures, where the mean was 98.2o and s = 0.62o , at the 0.05 significance level, test the claim that the mean body temperature of all healthy adults is equal to 98.6o.

39

H0 : = 98.6o

Ha : 98.6o

Example: Given a data set of 106 healthy body temperatures, where the mean was 98.2o and s = 0.62o , at the 0.05 significance level, test the claim that the mean body temperature of all healthy adults is equal to 98.6o.

Steps:

1) State the hypotheses

2) Determine the model

Two tail Z test, n > 30

40

3) Determine the Rejection Region

z = - 1.96 1.96

0.0250.025

0.47500.4750

= 0.05/2 = 0.025 (two tailed test)

41

4) Compute the test statistic

z = = = - 6.64x - µ 98.2 - 98.6

n0.62 106

42

RejectH0: µ = 98.6

RejectH0: µ = 98.6

Sample data:

x = 98.2o

or

z = - 6.64

z = - 1.96 µ = 98.6or z = 0

z = 1.96

z = - 6.64

Fail to RejectH0: µ = 98.6

5) State the Conclusion

REJECT H0

There is sufficient evidence to warrant rejection of claim that

the mean body temperatures of healthy adults is equal to 98.6o.

43

Assumptionsfor testing claims about population means

1) The sample is a simple random sample.

2) The sample is small (n 30).

3) The value of the population standard  deviation is unknown.

4) The sample values come from a population  with a distribution that is approximately  normal.

44

Test Statistic for a Student t-distribution

Critical ValuesFound in Table A-3

Degrees of freedom (df) = n -1

Critical t values to the left of the mean are negative

t = x -µxsn

45

Important Properties of the Student t Distribution

1. The Student t distribution is different for different sample sizes (see Figure 6-5 in Section 6-3).

2. The Student t distribution has the same general bell shape as the normal distribution; its wider shape reflects the greater variability that is expected with small samples.

3. The Student t distribution has a mean of t = 0 (just as the standard normal distribution has a mean of z = 0).

4. The standard deviation of the Student t distribution varies with the sample size and is greater than 1 (unlike the standard normal distribution, which has a = 1).

5. As the sample size n gets larger, the Student t distribution get closer to the normal distribution. For values of n > 30, the differences are so small that we can use the critical z values instead of developing a much larger table of critical t values. (The values in the bottom row of Table A-3 are equal to the corresponding critical z values from the normal distributions.)

46

Figure 7-11 Choosing between the Normal and Student t-Distributions when Testing a Claim about a Population Mean µ

Is n > 30

?

Is thedistribution of

the population essentiallynormal ? (Use a

histogram.)

No

Yes

Yes

No

No

Is known

?

Use normal distribution with

x - µx

/ nZ

(If is unknown use s instead.)

Use nonparametric methods, which don’t require a normal distribution.

Use normal distribution with

x - µx

/ nZ

(This case is rare.)

Use the Student t distributionwith x - µx

s/ nt

Start

47

The larger Student t critical value shows that with a small sample,

the sample evidence must be more extreme before we consider the

difference is significant.

48

A company manufacturing rockets claims to use anaverage of 5500 lbs of rocket fuel for the first 15 seconds ofoperation. A sample of 6 engines are fired and the mean fuelconsumption is 5690 lbs with a sample standard deviation of250 lbs. Is the claim justified at the 5% level of significance?

2. Two tail t test, n < 30, unknown population standard deviation

3. t critical for 5% for a two tail test with 5 d.f. is 2.571

86216250

550056904 .

ns

-μx. t

5. Fail to reject HO, there is no evidence at the .05 level that the average fuel consumption is different from µ = 5500 lbs

2.571-2.571 1.862

1. HO: µ = 5500 HA: µ 5500

49

P-Value Method

Table A-3 includes only selected values of

Specific P-values usually cannot be found

Use Table to identify limits that contain the P-value

Some calculators and computer programs will find exact P-values

50

P-Value Methodof Testing Hypotheses

very similar to traditional method

key difference is the way in which we decide to reject the null hypothesis

approach finds the probability (P-value) of getting a result and rejects the null hypothesis if that probability is very low

51

P-Value Methodof Testing Hypotheses

DefinitionP-Value (or probability value)

the probability that the test statistic is as far or farther from if the null hypothesis is true

The attained significance level of a hypothesis test is the P value of its test statistic

52

P-Value Methodof Testing Hypotheses

Guidelines for rejecting HO based on the P value:

If P < , then reject HO and accept HA

If P > , then reserve judgement about HO

53

Unusual sample results. Significant difference from the null hypothesis

Small P-values (such as 0.05 or lower)

P-value Interpretation

Large P-values (such as above 0.05)

Sample results are not unusual. Not a significant difference from the null hypothesis

54

Figure 7-8 Finding P-Values

Isthe test statistic

to the right or left ofcenter

?

P-value = areato the left of the test statistic

P-value = twice the area to the left of the test statistic

P-value = areato the right of the test statistic

Left-tailed Right-tailed

RightLeft

Two-tailed

P-value = twice the area to the right of the test statistic

Whattype of test

?

µ µ µ µ

P-value P-value is twicethis area

P-value is twicethis area

P-value

Test statistic Test statistic Test statistic Test statistic

Start

55

Testing Claims with Confidence Intervals

A confidence interval estimate of a population parameter contains the likely values of that parameter. We should therefore reject a claim that the population parameter has a value that is not included in the confidence interval.

56

Testing Claims with Confidence Intervals

95% confidence interval of 106 body temperature data (that is, 95% of samples would

contain true value µ )

98.08º < µ < 98.32º

98.6º is not in this interval

Therefore it is very unlikely that µ = 98.6º

Thus we reject claim µ = 98.6º

Claim: mean body temperature = 98.6º, where n = 106, x = 98.2º and s = 0.62º

57

Underlying Rationale of Hypotheses Testing

If, under a given observed assumption, the probability of getting the sample is exceptionally small, we conclude that the assumption is probably not correct.

When testing a claim, we make an assumption (null hypothesis) that contains equality. We then compare the assumption and the sample results and we form one of the following conclusions:

58

Underlying Rationale of Hypotheses Testing

If the sample results can easily occur when the assumption (null hypothesis) is true, we attribute the relatively small discrepancy between the assumption and the sample results to chance.

If the sample results cannot easily occur when that assumption (null hypothesis) is true, we explain the relatively large discrepancy between the assumption and the sample by concluding that the assumption is not true.

59

Type I ErrorThe mistake of rejecting the null hypothesis

when it is true.

(alpha) is used to represent the probability of a type I error

Example: Rejecting a claim that the mean body temperature is 98.6 degrees when the mean really does equal 98.6

60

Type II Errorthe mistake of failing to reject the null

hypothesis when it is false.

ß (beta) is used to represent the probability of a type II error

Example: Failing to reject the claim that the mean body temperature is 98.6 degrees when the mean is really different from 98.6

61

Type I and Type II Errors

True State of Nature

We decide to

reject the

null hypothesis

We fail to

reject the

null hypothesis

The null

hypothesis is

true

The null

hypothesis is

false

Type I error

(rejecting a true

null hypothesis)

Type II error

(rejecting a false

null hypothesis)

Correct

decision

Correct

decision

Decision

62

Controlling Type I and Type II Errors

For any fixed , an increase in the sample size n will cause a decrease in

For any fixed sample size n , a decrease in will cause an increase in . Conversely, an increase in will cause a decrease in .

To decrease both and , increase the sample size.