﻿ Statistical Methods - Lecture 8 HcWjnyVHiTd8hN_8STvJ2rWaXvhPz4wXYCNGvD4qDkU
Warning: include(../includes/menu_transparent.php) [function.include]: failed to open stream: No such file or directory in /home/content/07/8556507/html/misc/statistical_lecture_07.php on line 32

Warning: include() [function.include]: Failed opening '../includes/menu_transparent.php' for inclusion (include_path='.:/usr/local/php5/lib/php') in /home/content/07/8556507/html/misc/statistical_lecture_07.php on line 32

# The t TestsLecture 7

## The t Distribution

1. The t-tests are similar to the z-tests

1. However, you assumed you knew the population variance

2. In reality, the variance has to be estimated too!

3. Switch to the t distribution

1. The t-distribution is shorter and fatter because you estimated two parameters, the mean and the variance

2. The Rule of Thumb

1. If the observations are less than 30, then use the t-distribution

2. If the number of observations are equal to or greater than 31, then use the z-distribution as an approximation

1. Example

1. You survey 30 people in Almaty. The average income, = \$600 per month and variance, = 10,000

2. Find the 95% Confidence Interval

1. Use an a = 0.05 and df = 30 – 1 = 29

2. Using Excel, = tinv(a, df)

3. tc = 2.04523

4. If this was a normal distribution, then zc = 1.96

5. The standard error (SE) is

1. The 95% Confidence Interval is

1. There is a 95% chance that the true population mean lies between [562.5, 637.5]

## Testing the Means between Two Samples

1. Testing the Difference of the means of two samples

1. This is more complicated because you are estimating the variance

2. Two methods

1. If the variances are equal, then pool the variances

2. If the variances are unequal, then use a different method to pool the variance

3. Assume the variances are equal

4. Example

1. You survey 80 people at Mega Center

1. The average income is = \$800 per month

2. The estimated variance is = 10,000

2. You survey 60 people at Thieves’ Market

1. The average income is = \$500 per month

2. The estimated variance is = 2,500

3. Note – you should test data to determine if data is normally distributed

4. Variance is calculated at

 Variance in Sample 1 (n1 – 1) (80 -1)(10,000) 790,000 Variance in Sample 2 (n2 – 1) (60 – 1)(2,500) 147,500 Total Variance 937,500
1. Total degrees of freedom = n1 – 1 + n2 – 1 = 80 + 60 – 2 = 138

2. The pooled variance is

1. The standard error is

1. The t-statistic is

1. If a = 0.05, then the tc = 1.977304

2. The p-value is 5.01 X 10-15

3. The hypothesis test is

1. Reject the H0 and conclude the population means are different

1. Can use a Confidence Interval for hypothesis test

• If a = 0.05, df = 138, and tc=1.977304

1. Assume variances are unequal

1. Same example

2. The =10,000, n1 = 80, =2,500, and n2 = 60

1. However, we have to adjust the degrees of freedom

1. Round the degrees of freedom to 122

2. The t-statistic is

1. Reject the H0 and conclude the population means are different

## Difference of Means of Paired Observations

1. We have observations that are paired

2. Two treatments, A and B

3. Example: Patients are given two types of blood pressure medicine

 Observations Treatment A Treatment B Difference 1 64 84 -20 2 67 51 16 3 49 61 -12 . . . . 23 72 70 2
1. Calculate the average for the differences,

2. Calculate the standard deviation of the differences

1. The standard error is

1. The hypothesis test is

1. The t-statistic is

1. The a = 0.05, df = 23 – 1 = 22, and tc = tdist(a, df) = 2.034

1. Fail to reject the H0 and conclude both treatments are similar

2. The paired test is a more powerful test than the other two

3. Contains more information, because you took the extra step of pairing the observations

Warning: include(../includes/contact_information.php) [function.include]: failed to open stream: No such file or directory in /home/content/07/8556507/html/misc/statistical_lecture_07.php on line 470

Warning: include() [function.include]: Failed opening '../includes/contact_information.php' for inclusion (include_path='.:/usr/local/php5/lib/php') in /home/content/07/8556507/html/misc/statistical_lecture_07.php on line 470