Docsity
Docsity

Prepare for your exams
Prepare for your exams

Study with the several resources on Docsity


Earn points to download
Earn points to download

Earn points by helping other students or get them with a premium plan


Guidelines and tips
Guidelines and tips

Hypothesis Testing: Comparing Two Samples - Prof. Asatar P. Bair, Exams of Statistics

An introduction to hypothesis testing, focusing on comparisons between two samples. Using the example of greystone department stores and their difference in customer ages at city and suburban stores, the document explains how to estimate the difference between two means, the importance of interval estimates, and the concept of a sampling distribution. The document also covers three types of hypothesis tests: upper-tailed, lower-tailed, and two-tailed.

Typology: Exams

Pre 2010

Uploaded on 08/18/2009

koofers-user-twl
koofers-user-twl 🇺🇸

10 documents

1 / 6

Toggle sidebar

Related documents


Partial preview of the text

Download Hypothesis Testing: Comparing Two Samples - Prof. Asatar P. Bair and more Exams Statistics in PDF only on Docsity! Econ 5 Introduction to Statistics Asatar Bair, Ph.D. Department of Economics City College of San Francisco abair@ccsf.edu Lectures on Chapter 10 Hypothesis Testing: Comparisons Hypotheses involving comparisons In this section, we’re continuing our discussion of hypothesis testing, with application to the topic of whether two samples come from a population that is the same or different Example: Greystone Dept Stores Greystone Departments stores operates two stores in Buffalo, NY. One is in the city and the other is in a suburban mall. Some products sell better in one store than the other. Is it due to differences in the population, perhaps a difference in the average age? Suppose we want an estimate of the difference in the mean age of customers at the two stores. Example: Greystone Dept Stores Define the average age of the city store as !1 and the average age of the suburban store as !2. We’re interested in !1 - !2. However, we don’t know these population parameters, so we must rely on estimators, x1 and x2. Since x1 and x2 are both random variables, a point estimate of the difference would be simply: (x1 - x2) Example: Greystone Dept Stores The problem with the point estimate is that, although very precise, it is not very accurate, i.e. it is unlikely to be correct. So we need an interval estimate, to control the probability of making an error. Sampling Distribution of x1 - x2 x!1 - !2 x- 1 2 Again, we’re interested in both the shape of the distribution and its spread. x x- 1 2 E( ) = If n1 and n2 ! 30, or if population ~ N, the sampling distribution will be normal. ! " x 1#x 2 = "1 2 n1 + " 2 2 n2 x 1 # x 2( ) ± Margin of error x 1 # x 2( ) ± z$ / 2 "1 2 n1 + " 2 2 n2 40 # 35( ) ±1.96 9 2 35 + 10 2 49 = 5 ± 4.06 = 0.94, 9.06 z calc = x 1 # x 2( ) #D0 "1 2 n1 + " 2 2 n2 = (82# 78) # 0 102 30 + 102 40 =1.66 unbiased Interval Estimate City store Suburban store n1 = 36 n2 = 49 x1 = 40 years old x2 = 35 years old ! " x 1#x 2 = "1 2 n1 + " 2 2 n2 x 1 # x 2( ) ± Margin of error x 1 # x 2( ) ± z$ / 2 "1 2 n1 + " 2 2 n2 40 # 35( ) ±1.96 9 2 36 + 10 2 49 = 5 ± 4.06 = 0.94, 9.06 z calc = x 1 # x 2( ) #D0 "1 2 n1 + " 2 2 n2 = (82# 78) # 0 102 30 + 102 40 =1.66 " = 0.05 Example: Test scores ! " x 1#x 2 = "1 2 n1 + " 2 2 n2 x 1 # x 2( ) ± Margin of error x 1 # x 2( ) ± z$ / 2 "1 2 n1 + " 2 2 n2 40 # 35( ) ±1.96 9 2 36 + 10 2 49 = 5 ± 4.06 = 0.94, 9.06 z calc = x 1 # x 2( ) #D0 "1 2 n1 + " 2 2 n2 = (82# 78) # 0 102 30 + 102 40 =1.66 Calculating our test statistic, we get: Critical value = z"/2 = 1.96 p-value = 2(0.0485) = 0.0970 We reject the null hypothesis Test scores Fail to reject H0 Reject H0Reject H0 x0 x- 1 2 -1.96 1.96 1.66 4 Example: Test scores Conclusion: evidence from our sample is sufficient to reject the null hypothesis that !1 - !2 = 0; the sample evidence suggests that there is a difference between the population means. What if we don’t know !1 and !2? Clearwater Bank Clearwater Bank wants to know the difference between average checking account balance at two branches: Cherry Grove Beechmont n1 = 28 n2 = 22 x1 = $1025 x2 = $910 s1 = 10 s2 = 10 In this case, we don’t have !1 and !2, so we use s1 and s2. Interval Estimate " = 0.05 ! x 1 " x 2( ) ± t# / 2 s 1 2 n 1 + s 2 2 n 2 df = s1 2 n1 + s2 2 n2 $ % & ' ( ) 2 1 n1 "1 s1 2 n1 $ % & ' ( ) 2 + 1 n2 "1 s2 2 n2 $ % & ' ( ) 2 = 150 2 28 + 125 2 22 $ % & ' ( ) 2 1 28"1 150 2 28 $ % & ' ( ) 2 + 1 22 "1 125 2 22 $ % & ' ( ) 2 = 47.8 * 47 1025" 910( ) ± 2.012 150 2 28 + 125 2 22 = 115 ± 78 = 37, 193 tcalc = x 1 " x 2( ) "D0 s 1 2 n1 + s 2 2 n2 = (325" 286) " 0 40 2 12 + 44 2 12 = 2.27
Docsity logo



Copyright © 2024 Ladybird Srl - Via Leonardo da Vinci 16, 10126, Torino, Italy - VAT 10816460017 - All rights reserved