introduction to hypothesis testing › m1430f14 › 22 - hyp test 1 for means sigma … · in the...

Post on 03-Jul-2020

3 Views

Category:

Documents

0 Downloads

Preview:

Click to see full reader

TRANSCRIPT

σ known

(C) Kathleen A. Acker, Ph.D. 1

For Inferential Statistics we need a test that takes into account the possibility of sample error. The test used depends upon parameter under study.

We begin with hypothesis testing about sampling means.We know that the distribution of sampling means follows a Normal Distribution.

We shall assume that the population standard deviation is known.

(C) Kathleen A. Acker, Ph.D. 2

Traditional Method of Hypothesis Testing

Step 1: Identify hypothesis under consideration.

Right tailed, left tailed, two tailed

Step 2: Find a critical value.

Step 3: Calculate a test statistic

Compare the critical value and the test statistic to reach an answer.

Step 4: State your conclusion.

(C) Kathleen A. Acker, Ph.D. 3

In the first approach to hypothesis testing, we will compare the value of a Test Statistic to the value of a Critical Value.

Critical Value: Determination of the critical value depends upon the level of significance, α.

In general you will default to α=0.05 or α=0.01, however we are going to learn how to find a critical value for any level of significance.

(C) Kathleen A. Acker, Ph.D. 4

Let us work first with a two tailed test and let use a level of significance of α = 0.05.

0.5 – (0.05/2) = 0.475.

z value is ±1.96.

This is the critical value. (C) Kathleen A. Acker, Ph.D. 5

One-tailed test with α = 0.05

Visually this is the area in the tail of the distribution. All α = 0.05 falls into one tail.

0.5 - 0.05 = 0.45.

This corresponds toz = 1.645

This is the critical value.

(C) Kathleen A. Acker, Ph.D. 6

Please fill in the table with the appropriate z- values.

You can use this as a quick reference of Critical Values.

α 1-tail 2-tail

0.10

0.05 1.645 1.96

0.04

0.02

0.01

(C) Kathleen A. Acker, Ph.D. 7

Please fill in the table with the appropriate values.

You can use this as a quick reference of Critical Values.

α 1-tail 2-tail

0.10 1.285 1.645

0.05 1.645 1.96

0.04 1.75 2.055

0.02 2.055 2.325

0.01 2.325 2.575

(C) Kathleen A. Acker, Ph.D. 8

According to a 2004 study conducted by the University of Michigan, eighth grade boys spend an average of 23 hours a week playing video games. The population standard deviation is known to be σ =2.3 hours.

A professor at a competing university has decided to replicate the study. Data collected from 40 eighth grade boys yielded that they played video games on average 22.25 hours a week.

Test that the new study presents enough information to suggest that the average amount of time spent playing video games has changed since the University of Michigan study.

Test the hypothesis at α= 0.05.

(C) Kathleen A. Acker, Ph.D. 9

Step 1: State the hypothesis under consideration.

H0:μ= 23

H1:μ≠ 23

This is a two tailed test

Step 2: Determine the critical value. At α = 0.05 , the two tailed test CV is z = +/-1.96

(C) Kathleen A. Acker, Ph.D. 10

Step 3: Test Statistic

statistic-parameter

standard errorz

(C) Kathleen A. Acker, Ph.D. 11

n

xz

/

n

xz

/

06.2

40/3.2

2325.22

z

z

Compare the Critical Value and the Test Statistic Step 4: draw a conclusion.

(C) Kathleen A. Acker, Ph.D. 12

CV CVTS

Reject Null

There is statistical evidence to suggest that the average amount of time spent playing video games by eighth grade boys has changed from 23 hours a week.

How would your answer change if α = 0.01? The critical value would be z = +/- 2.575.

(C) Kathleen A. Acker, Ph.D. 13

TS

Fail to

Reject Null

CV CV

The new study does not present statistical evidence demonstrating that the average number of hours a week eighth grade boys spend playing video games is different to 23.

According to a 2004 study conducted by the University of Michigan, eighth grade boys spend an average of 23 hours a week playing video games. The population standard deviation is known to be σ = 2.3 hours.

A professor at a competing university has decided to replicate the study. Data collected from 40 eighth grade boys yielded that they played video games on average 22.25 hours a week.

Test that the new study presents enough information to suggest that the average amount of time spent playing video games has decreased since the University of Michigan study.

Test the hypothesis at α = 0.05.

(C) Kathleen A. Acker, Ph.D. 14

State the hypothesis under consideration.

H0:μ= 23

H1:μ < 23

Determine the critical value. α = 0.05 The critical value is z = -1.645

(C) Kathleen A. Acker, Ph.D. 15

Calculate the Test Statistic

n

xz

/

06.2

40/3.2

2325.22

z

z

(C) Kathleen A. Acker, Ph.D. 16

Draw a conclusion.

(C) Kathleen A. Acker, Ph.D. 17

CVTS

Reject Null

There is statistical

evidence to suggest

that the average

amount of time spent

playing video games

by eighth grade boys

has decreased from

23 hours a week.

We can calculate a corresponding critical value based on the scale of the original data.

If the sample mean (22.25) is large than 22.29 or smaller than 23.71, then we would fail to reject the null. Here we reject the null.

(C) Kathleen A. Acker, Ph.D. 18

x zn

0.05 23.71x

x zn

Upper

cut offLower

cut off

0.05

2.323 1.96 22.29

40x

Critical values with both scales

(C) Kathleen A. Acker, Ph.D. 19

CV CVTS

22.25

0

23

z

22.28 23.71

Method II: p-valueStep 1: Identify hypothesis under consideration.

Right tailed, left tailed, two tailed

Step 2: Calculate a test statistic

Step 3: Determine p-value.

Step 4: State your conclusion.

Compare p and α to reach a conclusion.

(C) Kathleen A. Acker, Ph.D. 20

According to a 2004 study conducted by the University of Michigan, eighth grade boys spend an average of 23 hours a week playing video games. The population standard deviation is known to be σ = 2.3 hours.

A professor at a competing university has decided to replicate the study. Data collected from 40 eighth grade boys yielded that they played video games on average 22.25 hours a week.

Test that the new study presents enough information to suggest that the average amount of time spent playing video games has decreased since the University of Michigan study.

Test the hypothesis at α = 0.05.

(C) Kathleen A. Acker, Ph.D. 21

Step 1: State the hypothesis under consideration.

H0:μ= 23

H1:μ< 23

This test is one-tailed.

Step 2: Calculate the Test Statistic

(C) Kathleen A. Acker, Ph.D. 22

22.25 232.06

/ 2.3 / 40

xz

n

Step 3: Calculate the area in the tail after the test statistic.

This area is a probability and it is the p-value.

p-value: P(z < -2.06) = 0.5- 0.4803 = 0.0197.

(C) Kathleen A. Acker, Ph.D. 23

Step 4: Draw a conclusion:0.0197 < 0.05 => p < αReject the Null.

If α= 0.01, then we would fail to reject.

If the test were two-tailed compare p and α/20.0197 < 0.025We reject the null.

(C) Kathleen A. Acker, Ph.D. 24

Method III: Confidence Interval

Step 1: Identify hypothesis under consideration.

Right tailed, left tailed, two tailed

Step 2: Calculate interval

Step 3: State your conclusion.

Determine if your parameter is within the interval and use the answer to reach a conclusion.

(C) Kathleen A. Acker, Ph.D. 25

(C) Kathleen A. Acker, Ph.D. 26

x zn

Point Estimate (Critical Value)(Standard Error)

According to a 2004 study conducted by the University of Michigan, eighth grade boys spend an average of 23 hours a week playing video games. The population standard deviation is known to be σ = 2.3 hours.

A professor at a competing university has decided to replicate the study. Data collected from 40 eighth grade boys yielded that they played video games on average 22.25 hours a week.

Find a 95% confidence interval of the population mean.

(C) Kathleen A. Acker, Ph.D. 27

Begin by finding the Critical Value.

Since the confidence level is 95%, α= 0.05. The corresponding two tailed critical value is z =1.96 .

(C) Kathleen A. Acker, Ph.D. 28

Since the confidence level is 95%, α= 0.05, the two tailed CV value is z =1.96

x z x zn n

(C) Kathleen A. Acker, Ph.D. 29

21.537 22.963

2.3 2.322.25 1.96 22.25 1.96

40 40

21.537 22.963

Applying to Hypothesis TestingH0:μ= 23H1:μ≠ 23

The Confidence Interval

Reject the null hypothesis, at α=0.05.

There is statistical evidence to suggest that the average amount of time spent playing video games, by eighth boys, is different to 23 hours per week.

(C) Kathleen A. Acker, Ph.D. 30

21.537 22.963

Repeat the test with a 99% level of confidence.At α=0.01, CV is z = 2.575.The Confidence Interval is:

(C) Kathleen A. Acker, Ph.D. 31

2.3 2.322.25 2.575 22.25 2.575

40 40

22.25 0.936429 22.25 0.936429

21.314 23.186

x z x zn n

Conclusion:

The Confidence Interval contains the hypothesis parameter 23.

Therefore we fail to reject the null hypothesis, at α=0.01.

There is no statistical evidence to suggest that the average amount of time spent playing video games, by eighth boys, is different to 23 hours per week.

(C) Kathleen A. Acker, Ph.D. 32

Notice that with all three methods, we rejected the null at the α = 0.05 level of significance and failed to reject at α = 0.01 level of significance.

(C) Kathleen A. Acker, Ph.D. 33

What if the test was one tailed?You can still construct an interval.

Note you are using the one tailed critical values for the corresponding level of significance.

x z x zn n

(C) Kathleen A. Acker, Ph.D. 34

Consider our previous left tailed example. Step 1: State the hypothesis under consideration.

H0:μ= 23

H1:μ< 23

Step 2: Calculate the confidence interval for α=0.05 and α=0.01.The corresponding one-tailed critical values are z = 1.645 and z = 2.325 respectively.

(C) Kathleen A. Acker, Ph.D. 35

α =0.05

α =0.01

2.3 2.322.25 1.645 22.25 1.645

40 40

21.652 22.848

x z x zn n

2.3 2.322.25 2.325 22.25 2.325

40 40

21.40 23.09

x z x zn n

(C) Kathleen A. Acker, Ph.D. 36

At α=0.05: The interval (21.652, 22.848) does not contain μ= 23. So we reject the null.

At α=0.01 The interval (21.40, 23.09) does contain μ= 23. So we fail to reject the null.

(C) Kathleen A. Acker, Ph.D. 37

Suppose there was a limit on the margin of error. How large of a sample would we need to meet this condition?

2

e zn

n ze

zn

e

(C) Kathleen A. Acker, Ph.D. 38

How many eighth grade boys should be sampled to keep the margin of error limited to 0.1? Round up. Assume α=0.05.

2 21.96*2.3

2032.20.1

2033

zn

e

n

(C) Kathleen A. Acker, Ph.D. 39

Stop. http://www.newsroom.msu.edu/site/indexer/

1943/content.htm

There are extra slides revisiting the comparison between a test statistic and critical value.

(C) Kathleen A. Acker, Ph.D. 40

If |Test Statistic| > |Critical Value|

Thenreject the null hypothesis.

(C) Kathleen A. Acker, Ph.D. 41

Reject Null

TS

If |Test Statistic| > |Critical Value|

Thenreject the null hypothesis.

(C) Kathleen A. Acker, Ph.D. 42

Reject Null

TS

Reject Null

TS

If |Test Statistic| < |Critical Value|

ThenFail to reject the null hypothesis.

(C) Kathleen A. Acker, Ph.D. 43

Fail to

Reject Null

TS

If |Test Statistic| < |Critical Value|

Thenreject the null hypothesis.

(C) Kathleen A. Acker, Ph.D. 44

Fail to

Reject Null

TS

top related