Previously, we discussed formulating and testing a hypothesis.

In this lesson, we will go a bit further using an example.

Coming back to the Burger King example,

suppose that the company,

based on previous studies on the willingness to pay for it's new burger,

found that the willingness to pay is $6.45.

And these studies have been done nationwide.

Now, Burger King wants to see if this willingness to pay for

the new burger is different or the same for West Coast markets in the United States.

So the question would be, do I use the same price or do I want

to have a different price for the West Coast?

Suppose that you administer a survey of respondents from the West Coast

and that the sample size is representative of the West Coast markets: California,

Washington State, and Oregon State.

So survey indicates that respondents, on average,

revealed that their willingness to pay for

the new burger is actually going to be about $7.

The marketing question here is,

can I conclude, based on this data,

that the willingness to pay on the West Coast is different,

and in fact, higher than the national level?

Here, I need to give you two additional pieces of information to move forward.

One is that the sample size is 1,000 and that the standard deviation is 1.3.

The first step is to formulate the statement that you think is

true of the population on the West Coast.

I need to formulate my hypothesis.

In this case, the null hypothesis, H0,

is that willingness to pay,

WTP, is equal to $6.45.

The alternative hypothesis, the hypothesis that you want to test,

is whether this willingness to pay is different in

the West Coast than in the overall population, the rest of the country.

And so that is the question you want to have in mind,

Is my willingness to pay different than $6.45?

What we want to do is to formulate the population's willingness to pay,

mu, is equal to $6.45.

The alternative hypothesis is that this willingness to pay is different than $6.45.

Again, what is common here is that we are going to use a 95% confidence level.

The next step is to compute the sample statistic which is given by the formula,

Z equal to X bar, the sample mean,

minus mu, the population parameter that we want to make an inference on, divided by S,

the standard deviation which is itself divided by the square root of n,

n being the sample size.

So, when I compute this number,

it's basically 7.01 minus 6.45

divided by 1.3 divided by square root of 1,000.

And that gives you about 13.6.

Now, the question is what do I do with this 13.6?

Based on the Z value for 95% confidence level,

I want to compare this number to the Z value

to the theoretical value at the 95% confidence level.

This value can be easily found in any statistical textbook or online and is 1.96.

Again, bear in mind that it turns out that this is the same 1.96 that we had before.

So, the decision rule is as follows: if your sample statistic

is greater than the theoretical value that is based on your confidence level,

then you can reject the null hypothesis

which means that the alternative hypothesis is supported.

So it's a bit of a coverted way of presenting this information.

But the basic heuristic is that this is good news.

If your sample statistic is greater than your theoretical value which is,

here in this case,

1.96, it means that you are in good shape.

Alternative hypothesis is supported by the data and you can

reject the null hypothesis with a 95% confidence level.

Here, 13.6 is greater than 1.96 which means that we can reject the null hypothesis.

Said differently, this means that the willingness to pay for

the new burger for the West Coast markets is higher than from the rest of the country.

The opposite conclusion would be true if you had

the sample statistics lower than the theoretical value Z.

In this case, the conclusion would have been that you cannot reject

the null hypothesis which means that

the alternative hypothesis is not supported in your data.

As you can imagine,

making such inferences can be prone to some statistical errors.

Specifically, there are two types of errors.

When you test hypotheses,

you have four potential scenarios.

So, first scenario is that the null hypothesis is actually true in

the population and the test tells you that you cannot reject the null hypothesis.

That means that the null hypothesis is correct and that,

in this case, you did not make a mistake.

Another scenario is that the null hypothesis is not true in

the population and the test tells you that you should reject it.

It's good news as well because it means that the test was correct.

Now, there are two tricky situations.

One situation would be that the null hypothesis is actually true in the population.

However, the test tells you that it is not and recommend to reject it.

It means that the test is incorrect.

Since the test is based on limited data,

it incorrectly infers that the null hypothesis is not supported and

the whole point here is to say that the null hypothesis is true

but the statistical tests tells you it is not.

That is called the Type 1 error.

As you can guess, the last possible scenario refers to a situation where

the null hypothesis is not true in the overall market but the test tells you otherwise.

This type of error is called the Type 2 error.