18
7b-1 Estim Unit 7b Statistical Inference - 2 Hypothesis Testing Using Data to Make Decisions FPP Chapters 27, 27, possibly 27 &/or 29 Z-tests for means Z-tests for proportions Cautions (Two sample tests) (Goodness-of-fit tests) A.05

7b-1 Estim Unit 7b Statistical Inference - 2 Hypothesis Testing Using Data to Make Decisions FPP Chapters 27, 27, possibly 27 &/or 29 Z-tests for means

Embed Size (px)

Citation preview

Page 1: 7b-1 Estim Unit 7b Statistical Inference - 2 Hypothesis Testing Using Data to Make Decisions FPP Chapters 27, 27, possibly 27 &/or 29 Z-tests for means

7b-1Estim

Unit 7b

Statistical Inference - 2Hypothesis Testing

Using Data to Make Decisions

FPP Chapters 27, 27, possibly 27 &/or 29

Z-tests for means

Z-tests for proportions

Cautions

(Two sample tests)

(Goodness-of-fit tests) A.05

Page 2: 7b-1 Estim Unit 7b Statistical Inference - 2 Hypothesis Testing Using Data to Make Decisions FPP Chapters 27, 27, possibly 27 &/or 29 Z-tests for means

7b-2Estim

Where we are

heading“With a one-tailed z-test, the null hypothesis was rejected at the 5% level. The difference must be regarded as statistically significant.”

How to set up, perform, & interpret statistical tests.

Page 3: 7b-1 Estim Unit 7b Statistical Inference - 2 Hypothesis Testing Using Data to Make Decisions FPP Chapters 27, 27, possibly 27 &/or 29 Z-tests for means

7b-3Estim

Terminology & Example

1. The manufacturer of grape-nuts flakes cereal claims that, on average, the contents of their boxes weigh at least 18 ounces. To check this claim, the contents of a random sample of 100 boxes can be weighed, and an inference can be based on the sample results.

Suppose the sample average was 17.97 ounces and the sample standard deviation was 0.09 ounces.

Is the difference between the observed average and the claimed average something real, or is it just chance variability?

Page 4: 7b-1 Estim Unit 7b Statistical Inference - 2 Hypothesis Testing Using Data to Make Decisions FPP Chapters 27, 27, possibly 27 &/or 29 Z-tests for means

7b-4Estim

Steps in Conducting aStatistical Test of Hypotheses

1. Identify the null hypothesis.

2. Identify the alternative hypothesis.

3. Select an appropriate summary statistic for this hypothesis test.

4. Compute the expected value and standard error for this summary statistic, assuming that the null hypothesis is true.

5. Use the sample data to calculate the value of the summary statistic.

6. Find the P-value (observed significance level).

7. Interpret the result.

Page 5: 7b-1 Estim Unit 7b Statistical Inference - 2 Hypothesis Testing Using Data to Make Decisions FPP Chapters 27, 27, possibly 27 &/or 29 Z-tests for means

7b-5Estim

Some Definitions

null hypothesis: A difference between observed and expected results is due to chance variation.

alternative hypothesis: A difference between observed and expected results is due to something real.

summary statistic: sample mean, sample proportion, … as appropriate to the problem at hand

test statistic: a measure of the difference between the observed data and what is expeccted under the null hypothesis

Page 6: 7b-1 Estim Unit 7b Statistical Inference - 2 Hypothesis Testing Using Data to Make Decisions FPP Chapters 27, 27, possibly 27 &/or 29 Z-tests for means

7b-6Estim

Definitions continuedz-test: a statistical test which uses the z-statistic

as a test statistic

z-statistic: (observed value - expected value)/SE

P-value, observed significance level, P: chance of getting a test statistic as extreme as or more extreme than the observed one, where this chance is computed based on the null hypothesis.

The smaller the P-value is, the stronger is the evidence against the null hypothesis. It is NOT the chance that the null hypothesis is correct.

Page 7: 7b-1 Estim Unit 7b Statistical Inference - 2 Hypothesis Testing Using Data to Make Decisions FPP Chapters 27, 27, possibly 27 &/or 29 Z-tests for means

7b-7Estim

Decision Making Using Significance Testing

P-value Decision

> 0.05 Result is not statistically significant. Do not reject the null hypothesis.

< 0.05 Result is statistically significant. Generally reject the null hypothesis in favor of the alternative hypothesis.

< 0.01 Result is highly statistically significant.

Reject the null hypothesis in favor of the alternative hypothesis.

Page 8: 7b-1 Estim Unit 7b Statistical Inference - 2 Hypothesis Testing Using Data to Make Decisions FPP Chapters 27, 27, possibly 27 &/or 29 Z-tests for means

7b-8Estim

Page 9: 7b-1 Estim Unit 7b Statistical Inference - 2 Hypothesis Testing Using Data to Make Decisions FPP Chapters 27, 27, possibly 27 &/or 29 Z-tests for means

7b-9Estim

More Examples

2. The accounts of a company show that, on average, accounts receivable are $954.10. An auditor checks a random sample of 144 of the accounts and finds a sample mean of $897.70 and standard deviation of $432.10.What would the auditor conclude regarding the company’s claim of average value $954.10?

Page 10: 7b-1 Estim Unit 7b Statistical Inference - 2 Hypothesis Testing Using Data to Make Decisions FPP Chapters 27, 27, possibly 27 &/or 29 Z-tests for means

7b-10Estim

Third Example

3. In contract negotiations, a company claims that a new incentive scheme has resulted in average weekly earnings of at least $400 for all production workers. A union representative takes a random sample of fifty workers and finds that their weekly earnings have an average of $385.50 and an SD of $32.60. How do we test statistically the company’s claim?

Page 11: 7b-1 Estim Unit 7b Statistical Inference - 2 Hypothesis Testing Using Data to Make Decisions FPP Chapters 27, 27, possibly 27 &/or 29 Z-tests for means

7b-11Estim

Hypothesis Testing

for a ProportionExample:A company receiving a shipment of

10,000 parts wants to accept delivery only if no more than 5% of the parts are defective. Their decision to take or refuse delivery is based on a check of a random sample of 200 parts.

In the sample, 13 parts are found to be defective. Test the hypothesis that the shipment defective rate is 5%.

Page 12: 7b-1 Estim Unit 7b Statistical Inference - 2 Hypothesis Testing Using Data to Make Decisions FPP Chapters 27, 27, possibly 27 &/or 29 Z-tests for means

7b-12Estim

Hypothesis Testingfor a Proportion

1. Identify the null hypothesis.

2. Identify the alternative hypothesis.

3. Select an appropriate summary statistic for this hypothesis test.

4. Compute the expected value and standard error for this summary statistic, assuming that the null hypothesis is true.

5. Use the sample data to calculate the value of the summary statistic.

6. Find the P-value (observed significance level).

7. Interpret the result.

Page 13: 7b-1 Estim Unit 7b Statistical Inference - 2 Hypothesis Testing Using Data to Make Decisions FPP Chapters 27, 27, possibly 27 &/or 29 Z-tests for means

7b-13Estim

Another Example

The federal Centers for Disease Control and Prevention (CDC) regularly conducts experiments as well as surveys. One survey, released Thurs. Nov 30, 2000 was conducted to assess what people know about AIDS. One question asked had to do with whether or not people thought it is possible to get AIDS by sharing a drinking glass with an infected person.

What proportion of the population do you hypothesize thinks that it is possible to get AIDS by sharing a drinking glass with an infected person?

Set up a hypothesis testing situation.

What is your null hypothesis?

What is your alternative hypothesis?…

Page 14: 7b-1 Estim Unit 7b Statistical Inference - 2 Hypothesis Testing Using Data to Make Decisions FPP Chapters 27, 27, possibly 27 &/or 29 Z-tests for means

7b-14Estim

Hypothesis Testingfor a Proportion

1. Identify the null hypothesis.

2. Identify the alternative hypothesis.

3. Select an appropriate summary statistic for this hypothesis test.

4. Compute the expected value and standard error for this summary statistic, assuming that the null hypothesis is true.

5. Use the sample data to calculate the value of the summary statistic.

6. Find the P-value (observed significance level).

7. Interpret the result.

Page 15: 7b-1 Estim Unit 7b Statistical Inference - 2 Hypothesis Testing Using Data to Make Decisions FPP Chapters 27, 27, possibly 27 &/or 29 Z-tests for means

7b-15Estim

Statistical Tests answer:“Could the difference between what we observed and what we expected be due to chance error?”

Statistical Tests do not answer:“Are the underlying assumptions met?”“Is the sample random?”“Is it okay to use a normal curve here?”“What caused the difference?”“Is the difference of practical importance?”

Interpretation of Significance

Tests

Page 16: 7b-1 Estim Unit 7b Statistical Inference - 2 Hypothesis Testing Using Data to Make Decisions FPP Chapters 27, 27, possibly 27 &/or 29 Z-tests for means

7b-16Estim

Cautions Regarding Statistical Tests of Significance

A statistical test of significance deals with the question of whether a difference is real, or due to chance variation.

Statistiacal tests of hypotheses are tests for statistical significance, not importance.

A small difference may be STATISTICALLY SIGNIFICANT, but may not be IMPORTANT.

The formulae will give you a number. It is up to YOU to check that appropriate assumptions are met.

The test does not check the design of the study.

Possible Errors: An observed difference may be “statistically significant” but still be due to chance. Even if the null hypothesis is correct, there is still a chance that we observe a statistically significant difference

Page 17: 7b-1 Estim Unit 7b Statistical Inference - 2 Hypothesis Testing Using Data to Make Decisions FPP Chapters 27, 27, possibly 27 &/or 29 Z-tests for means

7b-17Estim

Bricks example:We know from years of experience that the SD of the weights of the bricks produced is about 0.12 pounds.

If a random sample of 100 bricks is selected, the approximate level 95% confidence interval extends 0.024 pounds either side of the sample average.How large a sample should be taken to have approximate level 95% confidence interval be of width 0.04 pounds? (extending 0.02 either side of the sample average?)

How Large Should My

Sample Be?

Page 18: 7b-1 Estim Unit 7b Statistical Inference - 2 Hypothesis Testing Using Data to Make Decisions FPP Chapters 27, 27, possibly 27 &/or 29 Z-tests for means

7b-18Estim

Sample Size Computations for

ProportionsExample: The federal Centers for Disease Control and Prevention (CDC) regularly conducts experiments as well as surveys. One survey, released Thurs. Nov 30, 2000 was conducted to assess what people know about AIDS. One question asked had to do with whether or not people thought it is possible to get AIDS by being coughed or sneezed on by an infected person.

The CDC wants to estimate the proportion of people in the US population who think that it is possible to get AIDS by being coughed or sneezed on by an infected person. They want to estimate this proportion to within 0.02 with 95% confidence.

How large should their sample be?