Inference for Categorical Variables 2/29/12 Single Proportion, p Distribution Intervals and tests Difference in proportions, p 1 – p 2 One proportion or.

Slides:



Advertisements
Similar presentations
Chi-Square Tests 3/14/12 Testing the distribution of a single categorical variable :  2 goodness of fit Testing for an association between two categorical.
Advertisements

Statistics: Unlocking the Power of Data Lock 5 Testing Goodness-of- Fit for a Single Categorical Variable Kari Lock Morgan Section 7.1.
Statistics: Unlocking the Power of Data Lock 5 STAT 101 Dr. Kari Lock Morgan 10/23/12 Sections , Single Proportion, p Distribution (6.1)
Hypothesis Testing: Intervals and Tests
Hypothesis Testing I 2/8/12 More on bootstrapping Random chance
12.1 Inference for A Population Proportion.  Calculate and analyze a one proportion z-test in order to generalize about an unknown population proportion.
Statistical Significance What is Statistical Significance? What is Statistical Significance? How Do We Know Whether a Result is Statistically Significant?
Statistical Significance What is Statistical Significance? How Do We Know Whether a Result is Statistically Significant? How Do We Know Whether a Result.
Point and Confidence Interval Estimation of a Population Proportion, p
Statistics: Unlocking the Power of Data Lock 5 Hypothesis Testing: p-value STAT 101 Dr. Kari Lock Morgan 9/25/12 SECTION 4.2 Randomization distribution.
Statistics: Unlocking the Power of Data Lock 5 Inference for Proportions STAT 250 Dr. Kari Lock Morgan Chapter 6.1, 6.2, 6.3, 6.7, 6.8, 6.9 Formulas for.
ANOVA 3/19/12 Mini Review of simulation versus formulas and theoretical distributions Analysis of Variance (ANOVA) to compare means: testing for a difference.
Statistics: Unlocking the Power of Data Lock 5 Hypothesis Testing: Hypotheses STAT 101 Dr. Kari Lock Morgan SECTION 4.1 Statistical test Null and alternative.
1 Chapter 9 Inferences from Two Samples In this chapter we will deal with two samples from two populations. The general goal is to compare the parameters.
Warm-up Day of 8.1 and 8.2 Quiz and Types of Errors Notes.
Overview Definition Hypothesis
Inference for Proportions(C18-C22 BVD) C19-22: Inference for Proportions.
Section 5.2 Confidence Intervals and P-values using Normal Distributions.
Statistics: Unlocking the Power of Data Lock 5 Normal Distribution STAT 250 Dr. Kari Lock Morgan Chapter 5 Normal distribution Central limit theorem Normal.
Normal Distribution Chapter 5 Normal distribution
Section 10.1 ~ t Distribution for Inferences about a Mean Introduction to Probability and Statistics Ms. Young.
Statistics: Unlocking the Power of Data Lock 5 Synthesis STAT 250 Dr. Kari Lock Morgan SECTIONS 4.4, 4.5 Connecting bootstrapping and randomization (4.4)
Inference for a Single Population Proportion (p).
CHAPTER 20: Inference About a Population Proportion ESSENTIAL STATISTICS Second Edition David S. Moore, William I. Notz, and Michael A. Fligner Lecture.
Inference for Proportions
Statistics: Unlocking the Power of Data Lock 5 STAT 101 Dr. Kari Lock Morgan 11/1/12 ANOVA SECTION 8.1 Testing for a difference in means across multiple.
Inference for Quantitative Variables 3/12/12 Single Mean, µ t-distribution Intervals and tests Difference in means, µ 1 – µ 2 Distribution Matched pairs.
Statistics: Unlocking the Power of Data Lock 5 Normal Distribution STAT 101 Dr. Kari Lock Morgan 10/18/12 Chapter 5 Normal distribution Central limit theorem.
Lesson Comparing Two Proportions. Knowledge Objectives Identify the mean and standard deviation of the sampling distribution of p-hat 1 – p-hat.
Warm-up Day of 8.1 and 8.2 Review. 8.2 P#20, 23 and 24 P#20 a. and b. c. Since the p-hat is along the line for reasonably likely events.
Confidence intervals are one of the two most common types of statistical inference. Use a confidence interval when your goal is to estimate a population.
From the Data at Hand to the World at Large
1 Chapter 12: Inference for Proportions 12.1Inference for a Population Proportion 12.2Comparing Two Proportions.
Large sample CI for μ Small sample CI for μ Large sample CI for p
Lesson Comparing Two Proportions. Inference Toolbox Review Step 1: Hypothesis –Identify population of interest and parameter –State H 0 and H a.
10.1: Confidence Intervals Falls under the topic of “Inference.” Inference means we are attempting to answer the question, “How good is our answer?” Mathematically:
AP STATISTICS LESSON INFERENCE FOR A POPULATION PROPORTION.
The z test statistic & two-sided tests Section
Introduction to the Practice of Statistics Fifth Edition Chapter 6: Introduction to Inference Copyright © 2005 by W. H. Freeman and Company David S. Moore.
Lecture 9 Chap 9-1 Chapter 2b Fundamentals of Hypothesis Testing: One-Sample Tests.
Chapter 20 Testing Hypothesis about proportions
CHAPTER 20: Inference About a Population Proportion ESSENTIAL STATISTICS Second Edition David S. Moore, William I. Notz, and Michael A. Fligner Lecture.
Section 10.1 Estimating with Confidence AP Statistics February 11 th, 2011.
Statistics: Unlocking the Power of Data Lock 5 Exam 2 Review STAT 101 Dr. Kari Lock Morgan 11/13/12 Review of Chapters 5-9.
Introduction to Inference: Confidence Intervals and Hypothesis Testing Presentation 8 First Part.
Introduction to Inference: Confidence Intervals and Hypothesis Testing Presentation 4 First Part.
Statistics: Unlocking the Power of Data Lock 5 STAT 101 Dr. Kari Lock Morgan 10/30/12 Chi-Square Tests SECTIONS 7.1, 7.2 Testing the distribution of a.
Ch 12 – Inference for Proportions YMS 12.1
Minimum Sample Size Proportions on the TI Section
12.1 Inference for A Population Proportion.  Calculate and analyze a one proportion z-test in order to generalize about an unknown population proportion.
Copyright © 2013, 2009, and 2007, Pearson Education, Inc. Chapter 10 Comparing Two Groups Section 10.1 Categorical Response: Comparing Two Proportions.
Statistics: Unlocking the Power of Data Lock 5 Section 4.2 Measuring Evidence with p-values.
Statistics: Unlocking the Power of Data Lock 5 Inference for Means STAT 250 Dr. Kari Lock Morgan Sections 6.4, 6.5, 6.6, 6.10, 6.11, 6.12, 6.13 t-distribution.
Statistics: Unlocking the Power of Data Lock 5 Normal Distribution STAT 250 Dr. Kari Lock Morgan Chapter 5 Normal distribution (5.1) Central limit theorem.
Inference for Proportions Section Starter Do dogs who are house pets have higher cholesterol than dogs who live in a research clinic? A.
Statistics: Unlocking the Power of Data Lock 5 Inference for Means STAT 250 Dr. Kari Lock Morgan Sections 6.4, 6.5, 6.6, 6.10, 6.11, 6.12, 6.13 t-distribution.
Statistics: Unlocking the Power of Data Lock 5 Section 6.2 Confidence Interval for a Single Proportion.
Synthesis and Review 2/20/12 Hypothesis Tests: the big picture Randomization distributions Connecting intervals and tests Review of major topics Open Q+A.
Sullivan – Fundamentals of Statistics – 2 nd Edition – Chapter 11 Section 3 – Slide 1 of 27 Chapter 11 Section 3 Inference about Two Population Proportions.
Statistics: Unlocking the Power of Data Lock 5 Inference for Proportions STAT 250 Dr. Kari Lock Morgan Chapter 6.1, 6.2, 6.3, 6.7, 6.8, 6.9 Formulas for.
Statistics: Unlocking the Power of Data Lock 5 Section 6.3 Test for a Single Proportion.
Inference about proportions Example: One Proportion Population of students Sample of 175 students CI: What proportion (percentage) of students abstain.
Statistics: Unlocking the Power of Data Lock 5 Section 6.8 Confidence Interval for a Difference in Proportions.
Copyright © 2009 Pearson Education, Inc t LEARNING GOAL Understand when it is appropriate to use the Student t distribution rather than the normal.
4-1 Statistical Inference Statistical inference is to make decisions or draw conclusions about a population using the information contained in a sample.
Inference for a Single Population Proportion (p)
Hypothesis Testing.
Chapter 8: Inference for Proportions
Review of Chapter 10 Comparing Two Population Parameters
Presentation transcript:

Inference for Categorical Variables 2/29/12 Single Proportion, p Distribution Intervals and tests Difference in proportions, p 1 – p 2 One proportion or two? Distribution Intervals and tests Section 6.1, 6.2, 6.3, 6.7, 6.8, 6.9 Professor Kari Lock Morgan Duke University

Homework 5 (due Monday, 3/12) Homework 5 Project 1 (due Thursday, 3/22) Project 1 (NOTE: DUE DATE HAS CHANGED) To Do

Central Limit Theorem! For a sufficiently large sample size, the distribution of sample statistics for a mean or a proportion is normal

IF SAMPLE SIZES ARE LARGE… A confidence interval can be calculated by where z * is a N(0,1) percentile depending on the level of confidence. Interval Using N(0,1)

The standard error for a sample proportion can be calculated by SE of a Proportion *Notice the sample size in the denominator… as the sample size increases, the standard error decreases

If he is truly guessing randomly, then p = 0.5 so the SE of his sample proportion correct out of 8 guesses is Paul the Octopus

Paul the Octopus This is the same value we get from a randomization distribution…

If Paul really does have psychic powers, and can guess the correct team every time, then p = 1, and Paul the Octopus

Distribution of

If counts for each category are at least 10 (np ≥ 10 and n(1 – p) ≥ 10), then CLT for a Proportion

One small problem… if we are doing inference for p, we don’t know p! For confidence intervals, use your best guess for p: Standard Error

Confidence Interval for a Single Proportion

In head-to-head match ups Duke vs UNC in men’s basketball, UNC has won 131 and Duke has won 102. Duke vs UNC Men’s Basketball What is Duke’s probability of winning on Saturday? What do we have to assume? Is this reasonable??? Find a 95% CI.

Counts are greater than 10 in each category For a 95% confidence interval, z * = 2 Duke vs UNC Men’s Basketball

Other Levels of Confidence Technically, for 95% confidence, z* = 1.96, but 2 is much easier to remember, and close enough

z*z* -z * P% z* on TI-83 2 nd  DISTR  3: invNorm(  Proportion below z* (for a 95% CI, the proportion below z* is 0.975)

Margin of Error For a single proportion, what is the margin of error? a) b) c)

Margin of Error You can choose your sample size in advance, depending on your desired margin of error! Given this formula for margin of error, solve for n.

Margin of Error

Suppose we want to estimate a proportion with a margin of error of 0.03 with 95% confidence. How large a sample size do we need? (a)About 100 (b)About 500 (c)About 1000 (d) About 5000

IF SAMPLE SIZES ARE LARGE… A p-value is the area in the tail(s) of a N(0,1) beyond Tests Using N(0,1)

z-statistic If z = –3, using  = 0.05 we would (a) Reject the null (b) Not reject the null (c) Impossible to tell (d) I have no idea About 95% of z-statistics are within -2 and +2, so anything beyond those values will be in the most extreme 5%, or equivalently will give a p-value less than 0.05.

Hypothesis Testing For hypothesis testing, we want the distribution of the sample proportion assuming the null hypothesis is true What to use for p?

Hypothesis Testing The p-value is the area in the tail(s) beyond z in a N(0,1)

Using α = 0.05, is this evidence that one team is/was better than the other (combining past and present)? (a) Yes (b) No (c) No idea Duke vs UNC Men’s Basketball

Counts are greater than 10 in each category Based on this data, we cannot conclude that either Duke or UNC is significantly better.

Duke vs UNC Men’s Basketball

P% p-value on TI-83 2 nd  DISTR  3: normalcdf(  lower bound, upper bound Hint: if you want greater than 2, just put 2, 100 (or some other large number)

One Proportion or Two? Two proportions: there are two separate categorical variables One proportion: there is only one categorical variable

One Proportion or Two? Of residents in the triangle area, on Saturday night will the proportion of people cheering for Duke or UNC be greater? How much greater? a)Inference for one proportion b)Inference for two proportions (Note: assume no one will be cheering for both)

One Proportion or Two? Who is more likely to be wearing a blue shirt on Saturday night, a UNC fan or a Duke fan? a)Inference for one proportion b)Inference for two proportions

Standard Error for

CLT for If counts within each category (each cell of the two- way table) are at least 10

Metal Tags and Penguins Give a 90% confidence interval for the difference in proportions. Source: Saraux, et. al. (2011). “Reliability of flipper- banded penguins as indicators of climate change,” Nature, 469, Are metal tags detrimental to penguins? A study looked at the 10 year survival rate of penguins tagged either with a metal tag or an electronic tag. 20% of the 167 metal tagged penguins survived, compared to 36% of the 189 electronic tagged penguins.

Metal Tags and Penguins We are 90% confident that the survival rate is between 0.09 and lower for metal tagged penguins, as opposed to electronically tagged.

Hypothesis Testing What should we use for p 1 and p 2 in the formula for SE for hypothesis testing?

Pooled Proportion Overall sample proportion across both groups. It will be in between the two observed sample proportions.

Hypothesis Testing The p-value is the area in the tail(s) beyond z in a N(0,1)

Metal Tags and Penguins Are metal tags detrimental to penguins? (a) Yes (b) No (c) Cannot tell from this data 20% of the 167 metal tagged penguins survived, compared to 36% of the 189 electronic tagged penguins.

Metal Tags and Penguins Are metal tags detrimental to penguins?

Metal Tags and Penguins This is very strong evidence that metal tags are detrimental to penguins.

Metal Tags and Penguins

Accuracy The accuracy of intervals and p-values generated using simulation methods (bootstrapping and randomization) depends on the number of simulations (more simulations = more accurate) The accuracy of intervals and p-values generated using formulas and the normal distribution depends on the sample size (larger sample size = more accurate) If the distribution of the statistic is truly normal and you have generated many simulated randomizations, the p-values should be very close

For a single proportion: For a difference in proportions: Summary