One Sample and Two Sample T-tests

Slides:



Advertisements
Similar presentations
Introduction to Hypothesis Testing
Advertisements

Introductory Mathematics & Statistics for Business
Chapter 7 Hypothesis Testing
Inferential Statistics and t - tests
INTRODUCTORY STATISTICS FOR CRIMINAL JUSTICE
Hypothesis Testing with t Tests
Chapter 9 Introduction to the t-statistic
Testing Hypotheses About Proportions
Chapter 23 – Inferences About Means
Chapter 13 Comparing Two Populations: Independent Samples.
1 COMM 301: Empirical Research in Communication Lecture 15 – Hypothesis Testing Kwan M Lee.
Statistical Decision Making
Errors In it possible that we may reject the null hypothesis while in reality H 0 is true. This is known as a Type I error and we write that α=P(Type I.
Review: What influences confidence intervals?
1 Hypothesis Testing In this section I want to review a few things and then introduce hypothesis testing.
T-Tests Lecture: Nov. 6, 2002.
Lecture 7 PY 427 Statistics 1 Fall 2006 Kin Ching Kong, Ph.D
Chapter 9 Hypothesis Testing.
The one sample t-test November 14, From Z to t… In a Z test, you compare your sample to a known population, with a known mean and standard deviation.
Getting Started with Hypothesis Testing The Single Sample.
Chapter 9: Introduction to the t statistic
Chapter 9 Hypothesis Testing II. Chapter Outline  Introduction  Hypothesis Testing with Sample Means (Large Samples)  Hypothesis Testing with Sample.
Statistical Analysis. Purpose of Statistical Analysis Determines whether the results found in an experiment are meaningful. Answers the question: –Does.
Hypothesis Testing and T-Tests. Hypothesis Tests Related to Differences Copyright © 2009 Pearson Education, Inc. Chapter Tests of Differences One.
Chapter 8 Introduction to Hypothesis Testing. Hypothesis Testing Hypothesis testing is a statistical procedure Allows researchers to use sample data to.
Psy B07 Chapter 1Slide 1 ANALYSIS OF VARIANCE. Psy B07 Chapter 1Slide 2 t-test refresher  In chapter 7 we talked about analyses that could be conducted.
Statistics 11 Hypothesis Testing Discover the relationships that exist between events/things Accomplished by: Asking questions Getting answers In accord.
McGraw-Hill/IrwinCopyright © 2009 by The McGraw-Hill Companies, Inc. All Rights Reserved. Chapter 9 Hypothesis Testing.
Copyright © 2012 by Nelson Education Limited. Chapter 8 Hypothesis Testing II: The Two-Sample Case 8-1.
Confidence Intervals and Hypothesis Testing
Education 793 Class Notes T-tests 29 October 2003.
Sampling Distribution of the Mean Central Limit Theorem Given population with and the sampling distribution will have: A mean A variance Standard Error.
June 18, 2008Stat Lecture 11 - Confidence Intervals 1 Introduction to Inference Sampling Distributions, Confidence Intervals and Hypothesis Testing.
Single Sample Inferences
Chapter 9 Hypothesis Testing II: two samples Test of significance for sample means (large samples) The difference between “statistical significance” and.
Copyright © 2012 by Nelson Education Limited. Chapter 7 Hypothesis Testing I: The One-Sample Case 7-1.
Individual values of X Frequency How many individuals   Distribution of a population.
One-sample In the previous cases we had one sample and were comparing its mean to a hypothesized population mean However in many situations we will use.
Psy B07 Chapter 4Slide 1 SAMPLING DISTRIBUTIONS AND HYPOTHESIS TESTING.
From Theory to Practice: Inference about a Population Mean, Two Sample T Tests, Inference about a Population Proportion Chapters etc.
Inference We want to know how often students in a medium-size college go to the mall in a given year. We interview an SRS of n = 10. If we interviewed.
1 Lecture note 4 Hypothesis Testing Significant Difference ©
1 Psych 5500/6500 The t Test for a Single Group Mean (Part 1): Two-tail Tests & Confidence Intervals Fall, 2008.
DIRECTIONAL HYPOTHESIS The 1-tailed test: –Instead of dividing alpha by 2, you are looking for unlikely outcomes on only 1 side of the distribution –No.
Unit 8 Section 8-3 – Day : P-Value Method for Hypothesis Testing  Instead of giving an α value, some statistical situations might alternatively.
Reasoning in Psychology Using Statistics Psychology
Chapter 8 Parameter Estimates and Hypothesis Testing.
Stats Lunch: Day 3 The Basis of Hypothesis Testing w/ Parametric Statistics.
Aim: How do we use a t-test?
Review I A student researcher obtains a random sample of UMD students and finds that 55% report using an illegally obtained stimulant to study in the past.
© Copyright McGraw-Hill 2004
Applied Quantitative Analysis and Practices LECTURE#14 By Dr. Osman Sadiq Paracha.
Inference About Means Chapter 23. Getting Started Now that we know how to create confidence intervals and test hypotheses about proportions, it’d be nice.
Psychology 290 Lab z-tests & t-tests March 5 - 7, 2007 –z-test –One sample t-test –SPSS – Chapter 7.
Copyright © 2009 Pearson Education, Inc. 9.2 Hypothesis Tests for Population Means LEARNING GOAL Understand and interpret one- and two-tailed hypothesis.
Chapter 9 Introduction to the t Statistic
Hypothesis Testing – Two Means(Small, Independent Samples)
Hypothesis Testing: One Sample Cases
Hypothesis testing March 20, 2000.
Chapters 20, 21 Hypothesis Testing-- Determining if a Result is Different from Expected.
Central Limit Theorem, z-tests, & t-tests
Hypothesis Tests for a Population Mean,
Hypothesis tests for the difference between two means: Independent samples Section 11.1.
Review: What influences confidence intervals?
Reasoning in Psychology Using Statistics
Hypothesis Testing.
Reasoning in Psychology Using Statistics
Doing t-tests by hand.
Reasoning in Psychology Using Statistics
Reasoning in Psychology Using Statistics
Presentation transcript:

One Sample and Two Sample T-tests Introduce t test Hypothesis testing using a t test Paired t test Independent samples t test

Recap Single score compared to a known distribution Sample mean compared to a known sampling distribution (central limit theorem)

Example test of a hypothesis Say the 8:00 stats students average 6.85 hours of sleep on weeknights. UNT Daily reports that students as a whole average 7.5 hours of sleep per weeknight (standard deviation of 2.5). Do the stats students get less sleep on average?

Example test of a hypothesis Hypothesis: UNT students average 7.5 hours of sleep (s = 2.5) Data from stat students:

Example test of a hypothesis Z = -2.10 Consult table: what is the probability of coming up with a z value of -2.10 (which is just a transformation of our mean of 6.85) or more extreme ? p = .018

Example test of a hypothesis Another way to phrase our answer is that the probability of getting a mean of 6.85 or less hours slept when we were expecting 7.7 is .018. Question: are 8:00am stats students typical in their sleeping habits? Is their mean sleeping average significantly different than what we’d expect?

Example test of a hypothesis Formally Ho : μ = 7.7 H1 : μ ≠ 7.7 If the probability of the result is less than some criterion we’ve set up (e.g. p = .10), then we reject the null hypothesis (Ho ), and believe that our sample mean comes from a population with a mean that is different from the hypothesized population mean. The difference between the sample mean ( ) and the hypothesized population mean (μ) is statistically significant. Not just due to sampling error

One and two-tailed tests There are two ways to state our alternative hypothesis For example Ho : μ = 7.7 H1 : μ ≠ 7.7 However, seeing as we were dealing with an 8:00am class, it wouldn’t have seemed unlikely to have expected these folks to sleep less than typical UNT students. In other words H1 : μ < 7.7

One and two-tailed tests In the first case we have a non-directional hypothesis, also called a two-tailed test We are expecting extreme results that are some distance greater than or less than the hypothesized population mean (but we’re not sure which) In the second case we had a directional hypothesis, one-tailed test We expect our result to be greater than the hypothesized mean Or we expect our result to be greater than the hypothesized mean We only test one of these two outcomes

One and two-tailed tests What difference does it make? Say I was going to state that any outcome with a probability of < .05 would be deemed statistically significant What z-score am I hoping to find for a one-tailed test vs. a two-tailed test in order to claim significance?

One-tailed test H1: µ < some value H1: µ > some value

We don’t know if it’ll be greater than or less than Two-tailed test H1: µ ≠ some value We don’t know if it’ll be greater than or less than

One and two-tailed tests Note that the critical z-value that we’d need to reach the .05 level is different for each test. In the one-tailed situation, we only need a z score of +1.645 or –1.645 (depending on whether we our alternative hypothesis states that the result will be greater than or less than the hypothesized population mean) Gist: Easier to find a result that qualifies as significant (more statistical power) In the two-tailed situation, we need a z score of 1.96 Tougher

Two-tailed rejection Question: can you claim a directional result from a two-tailed test?

One and two-tailed tests Why don’t we just do a one-tailed test all the time? Sometimes we don’t know one way or another and/or are just looking for a difference of some kind Even when we have a good idea, our theory could be wrong Cover our ignorance

Limitation to the z-test We need to know  (population standard deviation) to compare things using our normal distribution tables Most situations we do not know 

Solution Remember that the standard deviation has properties that make it a very good estimate of the population value We can use our sample standard deviation to estimate the population standard deviation

T test Which leads to: where and remember degrees of freedom (n-1) Look familiar?

t distribution Gossett, who worked crunching numbers for the Guinness brewing company, had a few too many one day and stumbled upon the t distribution. Having enough wits about him to figure he might regret his actions the next day, he sent off his work to the journal under the pseudonym “Student”. However the work, like Guinness itself, has stood the test of time as a quality product Student’s t distribution We need to use a variety of distributions for t depending on df (sample size)

What’s the difference? Why a “t” now not a “z”? The difference involves using our sample standard deviation to estimate the population standard deviation Standard deviation is positively skewed, and so slightly underestimates the population value. Our standard error part of the formula will also be smaller than it should, which would lead to a larger value of z than should be

How is t different? Since s likely to be smaller than the appropriate value of s  more likely to produce a larger z than if we had used the actual s So instead we use the t-distribution which accounts for this Because we are trying to estimate , how well s does depends on the sample size The t-distribution is normal for an infinitely large sample size With larger samples our ‘important’ t-scores will be close to the ‘important’ z-scores (1.645, 1.96, 2.58)

What about when n is not large? Most of the time we do not have a very large n With smaller samples, s is more likely to underestimate s positively skewed sampling distribution of s As n gets larger and larger the t distribution more closely approximates the normal distribution

So now that we have something we call a t, how do we know what the critical value of t will be to reject the null hypothesis?

Looking up t distributions Table A.2 in book Use both df and a to determine the critical value a?? What the heck is a? I mean, what the heck is alpha? The alpha level is simply going to be whatever our criterion for statistical significance is going to be Our alpha level is associated with a particular t-value (critical value) It is also associated with making a type of error (but we’ll get to that later)

Looking up t distributions Normally if the printout of our results shows the p-value to be less than some criterion we’ve set up (e.g. .05), we reject the null hypothesis But I don’t have a printout! You calculate the t- score. If the t-score is beyond the critical t-value listed in the table that is associated with the .05 or .01 alpha levels (you get to pick your cutoff) for a one or two-tailed test, you reject the null hypothesis Saves having to write a t-score for every p-value possible like we did for the normal distribution Note: you would get a p-value from a stats program and should report it More info is better

Important point We will talk more about this later, but alpha level and the p-value are not the same thing We are entering dangerous territory!

Comparing t to z When a = .05, then z (two tails) = 1.96 What are the comparable values of t with: 1 df, 3 df, 5 df, 15 df, 30 df, 60 df, 120 df? Note your table: As with the z-test we performed, t-tests can be one-tailed or two

One vs Two-tailed test For which is it easier to obtain a ‘significant’ result- .05 one-tailed or .05 two-tailed test?

Previous Example: New version The UNT Daily claims in its recruiting literature that its students get an average of 8 hours of sleep a night (no s reported) Collected sleep data from 25 grad students, this sample has a mean of 7.2 hours sleep, s = 1.5

Plug in the numbers Formula where t= = = -2.667 = = -2.667 What else do we need to know?

Critical value of t Degrees of freedom (df) = n-1 = 25 - 1 = 24 Critical value at the .05 alpha level t.05(24) = +2.064 In this situation we are looking for a value greater than +2.064 or less than –2.064 (a two-tailed test) The t score observed from our data (-2.667) falls beyond the critical value Therefore p < .05 Conclusion?

Summary of hypothesis testing (or at least one way to go about it) 1) State the research question 2) State the null hypothesis, which simply gives us a value to test, and alternative hypothesis 3) Construct a sampling distribution based on the null hypothesis and locate region of rejection (i.e. find the critical value on your table) 4) Calculate the test statistic (t) and see where it falls along the distribution in relation to the critical value (tcv) 5) Reach a decision and state your conclusion

Your turn... The average grade from year to year in statistics courses at UNT is an 81. This year the stats students (200 thus far) have an average of 83 w/ s = 10. Is this unusual? tcv = ? p = ? t = ? Conclusion?