18
Statistics for Social and Behavioral Sciences Session #19: Estimation and Hypothesis Testing, Wrap-up & p-value (Agresti and Finlay, from Chapter 5 to Chapter 6) Prof. Amine Ouazad

Statistics for Social and Behavioral Sciences Session #19: Estimation and Hypothesis Testing, Wrap-up & p-value (Agresti and Finlay, from Chapter 5 to

Embed Size (px)

DESCRIPTION

True or False ?? For the test of a null hypothesis, the confidence interval method can only be applied when sample size N is large. For the test of a null hypothesis, the t test method can only be applied when the sample size is small. The sampling distribution of a t statistic is left-skewed, or right skewed, depending on the number of degrees of freedom. When testing a null hypothesis with 95% confidence level, the probability of a Type I error (i.e. when the null hypothesis is true) is 5%.

Citation preview

Page 1: Statistics for Social and Behavioral Sciences Session #19: Estimation and Hypothesis Testing, Wrap-up & p-value (Agresti and Finlay, from Chapter 5 to

Statistics for Socialand Behavioral Sciences

Session #19:Estimation and Hypothesis Testing,

Wrap-up & p-value(Agresti and Finlay, from Chapter 5 to Chapter 6)

Prof. Amine Ouazad

Page 2: Statistics for Social and Behavioral Sciences Session #19: Estimation and Hypothesis Testing, Wrap-up & p-value (Agresti and Finlay, from Chapter 5 to

Outline

1. True or False?

2. The p-value

3. One sided t tests

4. Type II error

Next time: Mid term covering Chapters 1—6 and 9 of A&F

Page 3: Statistics for Social and Behavioral Sciences Session #19: Estimation and Hypothesis Testing, Wrap-up & p-value (Agresti and Finlay, from Chapter 5 to

True or False ??• For the test of a null hypothesis, the confidence interval

method can only be applied when sample size N is large.

• For the test of a null hypothesis, the t test method can only be applied when the sample size is small.

• The sampling distribution of a t statistic is left-skewed, or right skewed, depending on the number of degrees of freedom.

• When testing a null hypothesis with 95% confidence level, the probability of a Type I error (i.e. when the null hypothesis is true) is 5%.

Page 4: Statistics for Social and Behavioral Sciences Session #19: Estimation and Hypothesis Testing, Wrap-up & p-value (Agresti and Finlay, from Chapter 5 to

Outline

1. True or False?

2. The p-value

3. One sided t tests

4. Type II error

Next time: Mid term covering Chapters 1—6 and 9 of A&F

Page 5: Statistics for Social and Behavioral Sciences Session #19: Estimation and Hypothesis Testing, Wrap-up & p-value (Agresti and Finlay, from Chapter 5 to

The p-value

is the probability (in other potential samples, unobserved) that the absolute value of the t statistic is greater than the observed t statistic in our sample.• A low p value means…..– that larger absolute values of the t test are unlikely.

In practice:• Reject the null hypothesis H0 at 95% if the p-value

is lower than 0.05.• Similarly for 90% and 99%! (0.10 and 0.01 resp.)

Page 6: Statistics for Social and Behavioral Sciences Session #19: Estimation and Hypothesis Testing, Wrap-up & p-value (Agresti and Finlay, from Chapter 5 to

Back to Amartya Sen: Are there really fewer women per man in India?

• “More than 100 million women are missing”

• Dataset collected by Simple Random Sampling.

• Population: Indian residents.• Sample: 2,878,380 respondents.• Little response bias.• Non response bias is possible.

Thomas W. Lamont University Professor, and Professor of

Economics and Philosophy, at Harvard University

Page 7: Statistics for Social and Behavioral Sciences Session #19: Estimation and Hypothesis Testing, Wrap-up & p-value (Agresti and Finlay, from Chapter 5 to

Back to Amartya Sen: Are there really fewer women per man in India?

Obtaining Table 5.1’s t scores values in Stata: type `display invttail(df,0.025)’ for 95%.Replace df by the degrees of freedom (N-1)

Page 8: Statistics for Social and Behavioral Sciences Session #19: Estimation and Hypothesis Testing, Wrap-up & p-value (Agresti and Finlay, from Chapter 5 to

• Either with the confidence interval method,• Or with the t test method,• We reject the null hypothesis:

“H0: the fraction of women in India is 50%”• At 99% (and thus at 95%, 90%).

• Draw the p-value on a graph of the distribution.

Back to Amartya Sen: Are there really fewer women per men in India?

Page 9: Statistics for Social and Behavioral Sciences Session #19: Estimation and Hypothesis Testing, Wrap-up & p-value (Agresti and Finlay, from Chapter 5 to

Outline

1. True or False?

2. The p-value

3. One sided t tests

4. Type II error

Next time: Mid term covering Chapters 1—6 and 9 of A&F

Page 10: Statistics for Social and Behavioral Sciences Session #19: Estimation and Hypothesis Testing, Wrap-up & p-value (Agresti and Finlay, from Chapter 5 to

Back to Cory Gardner• With 1850 respondents, the polling company PPP

found that 48% of respondents would vote for Gardner.

• Pollsters think that Gardner wins if the vote share is > 46%.

• Can you test the null hypothesis that the true vote share is = 46%, with Ha: vote share > 46% ?

Page 11: Statistics for Social and Behavioral Sciences Session #19: Estimation and Hypothesis Testing, Wrap-up & p-value (Agresti and Finlay, from Chapter 5 to

One sided test of H0: m=v, Ha: m>=v

• When testing m=v vs m>=v, use the t statistic method.– avoid the confidence interval method.

Assume that m=v and build t = (m-v)/SE. ☞ Reject the null hypothesis at 95%

if the t statistic is greater than +t0.05. ☞ Do not reject the null if t < 0.

• Similarly for 90% and 99% (t0.10 and t0.01).

Page 12: Statistics for Social and Behavioral Sciences Session #19: Estimation and Hypothesis Testing, Wrap-up & p-value (Agresti and Finlay, from Chapter 5 to

• Can we reject the null hypothesis at 95% with a one sided test?

• Can we reject the null hypothesis at 95% with a two sided test?

☞ Beware of the dangers of a one-sided test !!

Back to Cory Gardner

Page 13: Statistics for Social and Behavioral Sciences Session #19: Estimation and Hypothesis Testing, Wrap-up & p-value (Agresti and Finlay, from Chapter 5 to

Why it is objectionableto use one-sided tests….

• Assuming that the parameter is higher than a certain value….– Lowers the threshold t necessary to reject the null hypothesis.– For a one sided test, we use t0.05 for a test at 95%

– For a two sided test, we use t0.025 for a test at 95%.

• Ask yourself: Can I assume that the m will be necessarily higher than v?

Page 14: Statistics for Social and Behavioral Sciences Session #19: Estimation and Hypothesis Testing, Wrap-up & p-value (Agresti and Finlay, from Chapter 5 to

But here, not such a big issue: Are there really fewer women per man in India?

Obtaining one sided t scores values in Stata: type `display invttail(df,0.05)’ for 95%.Replace df by the degrees of freedom (N-1)

Page 15: Statistics for Social and Behavioral Sciences Session #19: Estimation and Hypothesis Testing, Wrap-up & p-value (Agresti and Finlay, from Chapter 5 to

Outline

1. True or False?

2. The p-value

3. One sided t tests

4. Type II error

Next time: Mid term covering Chapters 1—6 and 9 of A&F

Page 16: Statistics for Social and Behavioral Sciences Session #19: Estimation and Hypothesis Testing, Wrap-up & p-value (Agresti and Finlay, from Chapter 5 to

Type II error

• Type I error is well-known.• But what is the level of type II error?

Page 17: Statistics for Social and Behavioral Sciences Session #19: Estimation and Hypothesis Testing, Wrap-up & p-value (Agresti and Finlay, from Chapter 5 to

Wrap upConfidence interval method for the test of H0 : m = v. Ha: m ≠ v.CI = [ m – t * SE ; m + t * SE ]

– Reject the H0 with significance level 1% if the 99% confidence interval for the sample mean m does not include v.

– Reject the H0 with significance level 5% if the 95% confidence interval for the sample mean m does not include v.

– Reject the H0 with significance level 10% if the 90% confidence interval for the sample mean m does not include v.

t test method for the test of H0 : m = v. Ha: m ≠ v.– Build the t statistic (m-v)/SE– Reject the H0 with significance level 1%

if the t statistic is outside the range [-t0.005 , t0.005] – Reject the H0 with significance level 5%

if the t statistic is outside the range [-t0.025 , t0.025] – Reject the H0 with significance level 10%

if the t statistic is outside the range [-t0.05 , t0.05]

I will not ask for the one sided t-test, but good to know for your future life.

Page 18: Statistics for Social and Behavioral Sciences Session #19: Estimation and Hypothesis Testing, Wrap-up & p-value (Agresti and Finlay, from Chapter 5 to

Coming up: Readings:• Mid term on Tuesday, November 25.

– Coverage: up to Chapter 6 inclusive.

• No online quiz this week.• Make sure you come to sessions and recitations.

For help:

• Amine OuazadOffice 1135, Social Science [email protected] hour: Tuesday from 5 to 6.30pm.

• GAF: Irene [email protected] recitations. At the Academic Resource Center, Monday from 2 to 4pm.