Top Banner
BCOR 1020 Business Statistics Lecture 19 – April 1, 2008
32
Welcome message from author
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
Page 1: BCOR 1020 Business Statistics Lecture 19 – April 1, 2008.

BCOR 1020Business Statistics

Lecture 19 – April 1, 2008

Page 2: BCOR 1020 Business Statistics Lecture 19 – April 1, 2008.

Overview

• Chapter 9 – Hypothesis Testing– Logic of Hypothesis Testing– Testing a Proportion ()

Page 3: BCOR 1020 Business Statistics Lecture 19 – April 1, 2008.

Chapter 9 – Logic of Hypothesis Testing

What is a statistical test of a hypothesis?– Hypotheses are a pair of mutually exclusive, collectively

exhaustive statements about the world. – One statement or the other must be true, but they cannot

both be true.– We make a statement (hypothesis) about some

parameter of interest.– This statement may be true or false.– We use an appropriate statistic to test our hypothesis.– Based on the sampling distribution of our statistic, we can

determine the error associated with our conclusion.

Page 4: BCOR 1020 Business Statistics Lecture 19 – April 1, 2008.

Chapter 9 – Logic of Hypothesis Testing

5 Components of a Hypothesis Test:1. Level of Significance, – maximum probability of a

Type I Error • Usually 5%

2. Null Hypothesis, H0 – Statement about the value of the parameter being tested

• Always in a form that includes an equality

3. Alternative Hypothesis, H1 – Statement about the possible range of values of the parameter if H0 is false

• Usually the conclusion we are trying to reach (we will discuss.)• Always in the form of a strict inequality

Page 5: BCOR 1020 Business Statistics Lecture 19 – April 1, 2008.

Chapter 9 – Logic of Hypothesis Testing

5 Components of a Hypothesis Test:4. Test Statistic and the Sampling Distribution of the Test

statistic under the assumption that H0 is true (the equality in H0)

• Z and T statistics for now

5. Decision Criteria – do we reject H0 or do we “accept” H0?

• P-value of the test

or• Comparing the Test statistic to critical regions of its distribution

under H0.

Page 6: BCOR 1020 Business Statistics Lecture 19 – April 1, 2008.

Chapter 9 – Logic of Hypothesis Testing

Error in a Hypothesis Test:

• Type I error: Rejecting the null hypothesis when it is true.

= P(Type I Error) = P(Reject H0 | H0 is True)

• Type II error: Failure to reject the null hypothesis when it is false.

= P(Type II Error) = P(Fail to Reject H0 | H0 is False)

Page 7: BCOR 1020 Business Statistics Lecture 19 – April 1, 2008.

Chapter 9 – Logic of Hypothesis Testing

General Approach to Hypothesis Testing:• Select acceptable error levels

(always chosen before conducting the test) (often computed after the test has been conducted)

• Select Null and Alternative Hypotheses– Based on the problem objectives– A statistical hypothesis is a statement about the value of a

population parameter .– A hypothesis test is a decision between two competing mutually

exclusive and collectively exhaustive hypotheses about the value of

Page 8: BCOR 1020 Business Statistics Lecture 19 – April 1, 2008.

Chapter 9 – Logic of Hypothesis Testing

The Direction of the Hypothesis Test:• indicated by H1: > indicates a right-tailed test

< indicates a left-tailed test≠ indicates a two-tailed test

Page 9: BCOR 1020 Business Statistics Lecture 19 – April 1, 2008.

Chapter 9 – Logic of Hypothesis Testing

When to use a One- or Two-Sided Test:

• A two-sided hypothesis test (i.e., ≠ 0) is used when direction (< or >) is of no interest to the decision maker

• A one-sided hypothesis test is used when - the consequences of rejecting H0 are asymmetric, or - where one tail of the distribution is of special importance to the researcher.

• Rejection in a two-sided test guarantees rejection in a one-sided test, other things being equal.

Page 10: BCOR 1020 Business Statistics Lecture 19 – April 1, 2008.

Chapter 9 – Logic of Hypothesis Testing

General Approach to Hypothesis Testing:• Define an appropriate test statistic and its distribution

under the null hypothesis– This will vary depending on what parameter we are testing a

hypothesis about and the assumptions we use.

• Define your decision criteria– How do you decide whether to reject or “accept” H0?

Page 11: BCOR 1020 Business Statistics Lecture 19 – April 1, 2008.

Chapter 9 – Logic of Hypothesis Testing

Decision Rule:• A test statistic shows how far the sample estimate is

from its expected value, in terms of its own standard error.

• The decision rule uses the known sampling distribution of the test statistic to establish the critical value that divides the sampling distribution into two regions.

• Reject H0 if the test statistic lies in the rejection region.

Page 12: BCOR 1020 Business Statistics Lecture 19 – April 1, 2008.

Chapter 9 – Logic of Hypothesis Testing

Decision Rule for Two-Tailed Test:• Reject H0 if the test statistic < left-tail critical value or

if the test statistic > right-tail critical value.

Page 13: BCOR 1020 Business Statistics Lecture 19 – April 1, 2008.

Chapter 9 – Logic of Hypothesis Testing

Decision Rule for Left-Tailed Test:

• Reject H0 if the test statistic < left-tail critical value.

Decision Rule for Right-Tailed Test:• Reject H0 if the test

statistic > right-tail critical value.

Page 14: BCOR 1020 Business Statistics Lecture 19 – April 1, 2008.

Chapter 9 – Logic of Hypothesis Testing

Decision Rule:• , the probability of a Type I error, is the level of

significance (i.e., the probability that the test statistic falls in the rejection region even though H0 is true).

= P(reject H0 | H0 is true)

• A Type I error is sometimes referred to as a false positive.

• For example, if we choose = .05, we expect to commit a Type I error about 5 times in 100.

Page 15: BCOR 1020 Business Statistics Lecture 19 – April 1, 2008.

Chapter 9 – Logic of Hypothesis Testing

Decision Rule:• A small is desirable, other things being equal.• Chosen in advance, common choices for are

.10, .05, .025, .01 and .005 (i.e., 10%, 5%, 2.5%, 1% and .5%).

• The risk is the area under the tail(s) of the sampling distribution.

• In a two-sided test, the risk is split with /2 in each tail since there are two ways to reject H0.

Page 16: BCOR 1020 Business Statistics Lecture 19 – April 1, 2008.

Chapter 9 – Logic of Hypothesis Testing

• , the probability of a type II error, is the probability that the test statistic falls in the acceptance region even though H0 is false.

= P(fail to reject H0 | H0 is false)

• cannot be chosen in advance because it depends on and the sample size.

• A small is desirable, other things being equal.

Decision Rule:

Page 17: BCOR 1020 Business Statistics Lecture 19 – April 1, 2008.

Chapter 9 – Logic of Hypothesis Testing

Power of a Test:• The power of a test is the probability that a false

hypothesis will be rejected.• Power = 1 – • A low risk means high power.

• Larger samples lead to increased power.

Power = P(reject H0 | H0 is false) = 1 –

Page 18: BCOR 1020 Business Statistics Lecture 19 – April 1, 2008.

Chapter 9 – Logic of Hypothesis Testing

Relationship Between and :

• Both a small and a small are desirable.• For a given type of test and fixed sample size,

there is a trade-off between and .• The larger critical value needed to reduce risk

makes it harder to reject H0, thereby increasing risk.

• Both and can be reduced simultaneously only by increasing the sample size.

Page 19: BCOR 1020 Business Statistics Lecture 19 – April 1, 2008.

Chapter 9 – Logic of Hypothesis Testing

Choice of :• The choice of should precede the calculation of the

test statistic.

Significance versus Importance:• The standard error of most sample estimators

approaches 0 as sample size increases.

• In this case, no matter how small, – 0 will be significant if the sample size is large enough.

• Therefore, expect significant effects even when an effect is too slight to have any practical importance.

Page 20: BCOR 1020 Business Statistics Lecture 19 – April 1, 2008.

Chapter 9 –Testing a Proportion

Recall our motivating example for the discussion of confidence intervals:• Suppose your business is planning on bringing a new

product to market.• There is a business case to proceed only if

– the cost of production is less than $10 per unitand– At least 20% of your target market is willing to pay $25 per unit

to purchase this product.

• How do you determine whether or not to proceed?– You will likely conduct experiments/surveys to estimate these

variables and make appropriate inferences

Page 21: BCOR 1020 Business Statistics Lecture 19 – April 1, 2008.

Chapter 9 –Testing a Proportion

Motivating Example (continued) :• The percentage of your target market that is

willing to pay $25 per unit to purchase this product can be modeled as the probability of a “success” for a binomial variable.– You can conduct survey research on your target

market.– If 200 people are surveyed and 44 say they would pay

$25 to purchase this product, what can you conclude? – We will test an appropriate hypothesis to determine

whether the proportion of our target market that is willing to pay $25 per unit exceeds 20% (as required by the business case).

(Overhead)

Page 22: BCOR 1020 Business Statistics Lecture 19 – April 1, 2008.

Chapter 9 –Testing a Proportion

To Test a Hypothesis on a Proportion, :• Select your level of significance, .

– Usually we use = 0.05 (or 5%).

• Select your null and alternative hypotheses based on the problem statement.– Choose from…

* Since we are controlling , the conclusion we want to test is in H1.

(i) H0: > 0

H1: < 0

(ii) H0: < 0

H1: > 0

(iii) H0: = 0

H1: 0

where 0 is the null hypothesized value of (based on the problem statement).

Page 23: BCOR 1020 Business Statistics Lecture 19 – April 1, 2008.

Chapter 9 –Testing a Proportion

To Test a Hypothesis on a Proportion, :• Define the test statistic and its distribution under the null

hypothesis:– Start with the point estimate of , p = X/n– Recall that for a large enough n {n > 10 and n(1 – ) > 10}, p is

approximately normal with

n)1( 00

0

n)1( and

– If the null hypothesis is true, particularly if = 0, p is approximately normal with

and

– Based on this, we define the following test statistic which has an approximate standard normal distribution under H0…

n

pZ

)1(

0*

00

Page 24: BCOR 1020 Business Statistics Lecture 19 – April 1, 2008.

Chapter 9 –Testing a Proportion

To Test a Hypothesis on a Proportion, :• Define the decision criteria

– We will compare our test statistic to critical values (based on ) of its distribution under H0.

– If the test statistic is more extreme than the critical value of the null distribution, we reject H0 in favor of H1.

– Our comparison and depends on which of the three alternative hypotheses we are considering.

Page 25: BCOR 1020 Business Statistics Lecture 19 – April 1, 2008.

Chapter 9 –Testing a Proportion

To Test a Hypothesis on a Proportion, :• Define the decision criteria (continued)

(i) For the hypothesis test H0: > 0 vs. H1: < 0, we will reject H0 in favor of H1 if Z* < – Z.

(ii) For the hypothesis test H0: < 0 vs. H1: > 0, we will reject H0 in favor of H1 if Z* > Z.

(iii) For the hypothesis test H0: = 0 vs. H1: 0, we will reject H0 in favor of H1 if |Z*| > Z/2.

If we decide to reject H0 in favor of H1, then we say that there is statistically significant evidence that H0 is false and H1 is true. The probability that this conclusion is wrong is no greater than .

If we decide not to reject H0 in favor of H1, then we say that H0 is plausible (but we do not know the probability that this statement is wrong – yet).

Page 26: BCOR 1020 Business Statistics Lecture 19 – April 1, 2008.

Chapter 9 –Testing a Proportion

To Test a Hypothesis on a Proportion, :• Form Hypotheses• Collect data• Conduct test• Report results• Repeat and refine as necessary

Back to our motivating example…

Page 27: BCOR 1020 Business Statistics Lecture 19 – April 1, 2008.

Chapter 9 –Testing a Proportion

Example:• We will test an appropriate hypothesis to determine

whether the proportion of our target market that is willing to pay $25 per unit exceeds 20% (as required by the business case). If 200 people are surveyed and 44 say they would pay $25 to purchase this product, what can you conclude?

• Our point estimate, p = X/n = 44/200 =0.22 exceeds 20%. Does this mean we can conclude that the population proportion exceeds 20%?

• No! We must conduct the appropriate hypothesis test.

Page 28: BCOR 1020 Business Statistics Lecture 19 – April 1, 2008.

Chapter 9 –Testing a Proportion

Example (continued):• We will choose the level of significance, = 0.05. If

we reject H0, the probability that we have made an error (i.e. that H0 is true) will be no greater than 5%.

• We must choose the appropriate null and alternative hypotheses. Recall that the conclusion we are hoping to test should be in the alternative.

Since we want to determine whether exceeds 20%, we want to test…

(ii) H0: < 0

H1: > 0

Page 29: BCOR 1020 Business Statistics Lecture 19 – April 1, 2008.

Chapter 9 –Testing a ProportionExample (continued):

• We calculate our test statistic for the test of the proportion…

200)80.0(20.0)1(

0* 20.022.000

n

pZ

71.0* Z

ii. For the hypothesis test H0: < 0 vs. H1: > 0, we will reject H0 in favor of H1 if Z* > Z.

• We define our rejection criteria and make a decision based on the data.

Since we chose = 0.05, Z = Z.05 = 1.645.

Since Z* = 0.71 is not greater than Z.05 = 1.645, we will fail to reject H0 in favor of H1.

N(0,1) if H0 is true.

Page 30: BCOR 1020 Business Statistics Lecture 19 – April 1, 2008.

Chapter 9 –Testing a Proportion

Example (continued):• We state the conclusion of our hypothesis test in clear

language.

• Since Z* = 0.71 is not greater than Z.05 = 1.645, we will fail to reject H0 in favor of H1. (This is probably not clear to someone who is not a statistician.)

• “Based on the data in our study, there is not statistically significant evidence that the proportion of our target market that is willing to pay $25 per unit exceeds 20%.”

Page 31: BCOR 1020 Business Statistics Lecture 19 – April 1, 2008.

Chapter 9 –Testing a Proportion

Calculating the p-value of the test:• The p-value of the test is the exact probability of a type I

error based on the data collected for the test. It is a measure of the plausibility of H0.

– P-value = P(Reject H0 | H0 is True) based on our data.

– Formula depends on which pair of hypotheses we are testing…

*2 ZZPvaluep

(i) For the hypothesis test H0: > 0 vs. H1: < 0,

(ii) For the hypothesis test H0: < 0 vs. H1: > 0,

(iii) For the hypothesis test H0: = 0 vs. H1: 0,

)( *ZZPvaluep

)( *ZZPvaluep

Page 32: BCOR 1020 Business Statistics Lecture 19 – April 1, 2008.

Chapter 9 –Testing a ProportionExample: Let’s calculate the p-value of the test in our example…• We found Z* = 0.71

• Since we were testing H0: < 0 vs. H1: > 0,

2389.0)71.0()( * ZPZZPvaluep

-0.71

Area = 0.2839

Interpretation:If we were to reject H0 based on the observed data, there is a 28% chance we would be making a type I error. Since this is larger than = 5%, we will not reject H0.