42
Hypothesis Testing

Hypothesis Testing

Embed Size (px)

DESCRIPTION

 

Citation preview

Page 1: Hypothesis Testing

Hypothesis Testing

Page 2: Hypothesis Testing

An example…

Suppose that we want to compare the crime rate in Uttar Pradesh with the crime rate in the rest of the country. Is there more or less crime in UP than

the national average?

Page 3: Hypothesis Testing

An example…

First, we start with the hypothesis that the crime rate on average in UP is the same as the national average.

To test our hypothesis, we ask what sample means would occur if many samples of the same size were drawn at random from our population if our hypothesis is true.

Page 4: Hypothesis Testing

An example…

We can now refer to the sampling distribution of the mean, for an infinite series of samples of size n, drawn from a population whose mean is the same as the national average, and we compare our sample mean with those in this sampling distribution.

If our hypothesis is true, then the distribution of sample means will be centered about the national average.

Page 5: Hypothesis Testing

An example…

Suppose that the relationship between our sample mean and those of the sampling distribution of the mean looks like this…

Our obtained value.

Our hypothesized value.

Page 6: Hypothesis Testing

An example…

If so, our sample mean is one that could reasonably occur if the hypothesis is true, and we will retain our hypothesis as one that could be true. (The crime rate of UP is the same as the national average.)

Page 7: Hypothesis Testing

An example…

On the other hand, if the relationship between our sample mean and those of the sampling distribution of the mean looks like this…

Page 8: Hypothesis Testing

An example…

Our sample mean is so deviant that it would be quite unusual to obtain such a value when our hypothesis is true. In this case, we would reject our hypothesis and conclude that it is more likely that the crime rate of UP is not the same as the national average. The population represented by the

sample differs significantly from the comparison population.

Page 9: Hypothesis Testing

Null Hypothesis

The hypothesis that we put to the test is called the null hypothesis, symbolized H0.

The null hypothesis usually states the situation in which there is no difference (the difference is “null”) between populations.

Page 10: Hypothesis Testing

Alternative Hypothesis

The alternative hypothesis, symbolized HA, is the opposite of the null hypothesis.The alternative hypothesis is also identified as the research hypothesis, or the “hunch” that the investigator wants to test.

Page 11: Hypothesis Testing

Null and Alternative Hypotheses

Both H0 and HA are statements about population parameters, not sample statistics.A decision to retain the null hypothesis implies a lack of support for the alternative hypothesis.A decision to reject the null hypothesis implies support for the alternative hypothesis.

Page 12: Hypothesis Testing

When do we retain and when do we reject the null hypothesis?

When we draw a random sample from a population, our obtained value of the sample mean will almost never exactly equal the mean of our population.The decision to reject or retain the null hypothesis depends on the selected criterion for distinguishing between those sample means that would be common and those that would be rare if H0 was true.

Page 13: Hypothesis Testing

When do we retain and when do we reject the null hypothesis?

If the sample mean is so different from what is expected when H0 is true that its appearance would be unlikely, H0 should be rejected.But what degree of rarity of occurrence is so great that it seems better to reject the null hypothesis than to retain it?

Page 14: Hypothesis Testing

When do we retain and when do we reject the null hypothesis?

This decision is somewhat arbitrary, but common research practice is to reject H0 if the sample mean is so deviant that its probability of occurrence in random sampling is .05 or less.Such a criterion is called the level of significance, symbolized .

Page 15: Hypothesis Testing

Rejection Regions

For our purposes, we will adopt the .05 level of significance.Therefore, we will reject H0 only if our obtained sample mean is so deviant that it falls in the upper 2.5% or lower 2.5% of all the possible sample means that would occur when H0 is true.

The portions of the sampling distribution that include the values of the mean that lead to rejection of the null hypothesis are called rejection regions.

If our sample mean falls in the middle 95% of the distribution of all possible values of the mean that could occur when H0 is true, we will retain the null hypothesis.

Page 16: Hypothesis Testing

What sample means would occur if H0 is true?

If it is true, the sampling distribution of the mean would center on the hypothesized population mean.If we assume that the sampling distribution of the mean approximates a normal curve (and we can, if our sample size satisfies the central limit theorem)…

Page 17: Hypothesis Testing

Critical Values

We can use the normal curve table to calculate the Z values, called critical values, that separate the upper 2.5% and lower 2.5% of sample means from the remainder.

Page 18: Hypothesis Testing

An example…

Suppose our obtained sample mean of the crime rate in UP is a score of 90 (100 villages/towns).Suppose that the national average is known to be 85, with a standard deviation of 20Even if the population mean really is a score of 85, because of random sampling variation we do not expect the mean of a sample randomly drawn from a population to be exactly 85 (although it could be).

Page 19: Hypothesis Testing

Using the Sampling Distribution of the Mean to Determine Probability

The important question is what is the relative position of the obtained sample mean among all those that could have been obtained if the hypothesis is true?To determine the position of the obtained sample mean, it must be expressed as a Z score.

Page 20: Hypothesis Testing

Z score

Before, you were finding the Z score of a single individual on a distribution of a population of individuals.In hypothesis testing, you are finding a Z score of your sample’s mean on a distribution of means.

Page 21: Hypothesis Testing

Z Score Formulas

The method of changing the sample’s mean to a Z score is the same as changing an individual’s score to a Z score.

mean theoferror standard

ondistributi sampling ofmean -mean sampleXZ

:ondistributi sampling an mean withi sample a locate To

deviation standard population

mean population-scoreZ

:population a within score raw a locate To

deviation standard sample

mean sample-scoreZ

:sample a within score raw a locate Toscores ofdeviation standard

scores ofmean -score Z

:generalIn

X

X

X

S

XX

Page 22: Hypothesis Testing

An example…

In our study,

mean theoferror standard

) trueis Ho(when mean population edhypothesizmean sample obtainedZ

5.22

5

100

208590

Z

Page 23: Hypothesis Testing

An example…

Our sample mean is 2.5 standard errors of the mean greater than expected if the null hypothesis were true.The value of 2.5 falls in the rejection region, so we reject H0 and retain HA.We can conclude that the mean of the population from which the sample came from is not 85.

Page 24: Hypothesis Testing

An example…

The crime rate of UP is, on average, different from (greater than) other states of the country.Notice that the conclusion is about the population represented by the sample under study and not simply the particular sample itself.

Page 25: Hypothesis Testing

What if we had used = .01?

Our sample mean, and our Z value would still be the same, but the critical values of Z that separate the regions of rejection would be different, 2.58.This is a more conservative value (it is harder to reject the null hypothesis).Your decision depends on your criterion.

Using an alpha level of .01, you would fail to reject the null hypothesis.

Page 26: Hypothesis Testing

If we retain H0, what can we conclude?

The decision to retain H0 does not mean that it is likely that H0 is true.Rather, this decision reflects the fact that we do not have sufficient evidence to reject the null hypothesis.Certain other hypotheses would also have been retained if tested in the same way.

Page 27: Hypothesis Testing

If we retain H0, what can we conclude?

Consider our example where the hypothesized population mean is 85.If we had obtained a sample mean of 86, the null hypothesis would have been retained.But suppose the hypothesized population mean was 87.If we had obtained a sample mean of 86, the null hypothesis would also have been retained.

Page 28: Hypothesis Testing

Strength of Decision

Rejecting the null hypothesis means that H0 is probably false, a strong decision.Retaining the null hypothesis is a weak decision.

Page 29: Hypothesis Testing

Two-tailed Test

The alternative hypothesis states that the population parameter may be either less than or greater than the value stated in H0.

The critical region is divided between both tails of the sampling distribution.

Page 30: Hypothesis Testing

Two-tailed Test

This type of test is desirable in most research situations. For example, in most cases in which

the performance of a group is compared to a known standard, it would be of interest to discover that the group is superior or inferior.

Page 31: Hypothesis Testing

One-tailed Test

The alternative hypothesis states that the population parameter differs from the value stated in H0 in one particular direction. The critical region is located only in

one tail of the sampling distribution.

Page 32: Hypothesis Testing

One-tailed Test

Upper-tail Critical Lower-tail Critical

Page 33: Hypothesis Testing

One-tailed Test

The advantage of a one-tailed test is that it is more sensitive to detecting a false hypothesis in the direction of concern than a two-tailed test.The major disadvantage of a one-tailed test is that it precludes any chance of discovering that reality is just the opposite of what the alternative hypothesis says.

Page 34: Hypothesis Testing

Steps of the Hypothesis Test

1. State the research question.2. State the statistical hypothesis.3. Set decision rule.4. Calculate the test statistic.5. Decide if result is significant.6. Interpret result as it relates to

your research question.

Page 35: Hypothesis Testing

An example…

Robins and John (1997) carried out a study on narcissism (self-love), comparing people who had scored high versus low on a narcissism questionnaire. (An example item was “If I ruled the world it would be a better place.”) They also had other questionnaires, including one that had an item about how many times the participant looked in the mirror on a typical day. They hypothesize that people who scored high on the narcissism scale look in the mirror significantly more often than people who did not score high on the scale. Based on previous research, it is known that, on average, a person looks in the mirror 4.8 times per day, with a standard deviation of 2.6. Taking a sample of 25 narcissistic individuals, they find a mean of 6.3 visits to the mirror per day. Using the .05 level of significance, and assuming the distribution approximates a normal curve, what should the researchers conclude?

Page 36: Hypothesis Testing

An example…

State the research question: Do individuals, who score high on a

narcissistic scale, look at themselves in the mirror significantly more often than individuals who are not narcissistic?

State the statistical hypothesis:8.4:

8.4:0

AH

H

Page 37: Hypothesis Testing

Statistical Hypotheses

Two-tailed Test

One-Tailed Test Lower-tailed

Upper-tailed

XH

XH

A

:

:0

XH

XH

A

:

:0

XH

XH

A

:

:0

Page 38: Hypothesis Testing

An example…

Set decision rule:

65.1

05.

critZ

Page 39: Hypothesis Testing

An example…

Calculate the test statistic:

88.2

25

6.28.43.6

25,6.2,8.4

Z

XZ

n

X

hyp

Page 40: Hypothesis Testing

An example…

Decide if results are significant: Reject H0, 2.88 > 1.65.

Interpret results as it relates to the statistical hypothesis:

Narcissistic individuals look in the mirror significantly more often than individuals who are not narcissistic.

Page 41: Hypothesis Testing

Another example…

A psychologist is working with people who have had a particular type of major surgery. The psychologist proposes that people will recover from the operation more quickly if friends and family are in the room with them for the first 48 hours after the operation (based on several other studies on social support), but acknowledges that the presence of friends and family may also slow recovery time, due to the added activity and possible stress associated with visitors. It is known that time to recover from this kind of surgery is normally distributed with a mean of 12 days and a standard deviation of 5 days. The procedure of having friends and family in the room for the period after the surgery is done with 9 randomly selected patients. The patients recover in an average of 8 days. Using the .01 level of significance, what should the researcher conclude?

Page 42: Hypothesis Testing

Another example…

State the research hypothesis:

State the statistical hypothesis:Set decision rule:Calculate the test statistic:Decide if results are significant:

Interpret results as it relates to the statistical hypothesis:

12:

12:

A

o

H

H

58.2critZ

40.2

9

5128

Z

Do patients who have friends and family with them following surgery recover more or less quickly than people who do not?

Patients who have friends and family with them following surgery do not recover significantly faster, or slower, than patients who do not have social support.

Retain H0, -2.40 > -2.58