# Hypothesis Testing with Two Samples

## Matched or Paired Samples (Optional)

When using a hypothesis test for matched or paired samples, the following characteristics should be present:
1. Simple random sampling is used.
2. Sample sizes are often small.
3. Two measurements (samples) are drawn from the same pair of individuals or objects.
4. Differences are calculated from the matched or paired samples.
5. The differences form the sample that is used for the hypothesis test.
6. Either the matched pairs have differences that come from a population that is normal or the number of differences is sufficiently large so that distribution of the sample mean of differences is approximately normal.
In a hypothesis test for matched or paired samples, subjects are matched in pairs and differences are calculated. The differences are the data. The population mean for the differences, μ, is then tested using a Student’s-t test for a single population mean with n – 1 degrees of freedom, where n is the number of differences.
The test statistic (t-score) is

### Chapter Review

A hypothesis test for matched or paired samples (t-test) has these characteristics:
1. Test the differences by subtracting one measurement from the other measurement
2. Random variable: 
 = mean of the differences.
3. Distribution:  Student’s t distribution with n – 1 degrees of freedom.
4. If the number of differences is small (less than 30), the differences must follow a normal distribution.
5. Two samples are drawn from the same set of objects.
6. Samples are dependent.

### Formula Review

Test statistic (t-score): t = 

where:

 is the mean of the sample differences, μd is the mean of the population differences, s is the sample standard deviation of the differences, and n is the sample size.
Use the following information to answer the next five exercises. A study was conducted to test the effectiveness of a software patch in reducing system failures over a six-month period. Results for randomly selected installations are shown in . The before value is matched to an after value, and the differences are calculated. The differences have a normal distribution. Test at the 1 percent significance level.
Use the following information to answer next five exercises. A study was conducted to test the effectiveness of a juggling class. Before the class started, six subjects juggled as many balls as they could at once. After the class, the same six subjects juggled as many balls as they could. The differences in the number of balls are calculated. The differences have a normal distribution. Test at the 1 percent significance level.
Use the following information to answer the next five exercises. A doctor wants to know if a blood pressure medication is effective. Six subjects have their blood pressures recorded. After twelve weeks on the medication, the same six subjects have their blood pressure recorded again. For this test, only systolic pressure is of concern. Test at the 1 percent significance level.

### Homework

DIRECTIONS: For each of the word problems, use a solution sheet to do the hypothesis test. The solution sheet is found in 
Use the following information to answer the next two exercises. A new preventative medication was tried on a group of 224 patients who had the same risk factors for a disease. 45 patients developed the disease after four years. In a control group of 224 patients, 68 developed the disease after four years. We want to test whether the method of treatment reduces the proportion of patients who develop the disease after four years.
Let the subscript t = treated patient and ut = untreated patient.
Use the following information to answer the next two exercises. An experiment is conducted to show that blood pressure can be consciously reduced in people trained in a biofeedback exercise program. Six subjects were randomly selected, and blood pressure measurements were recorded before and after the training. The difference between blood pressures was calculated (after – before), producing the following results: 
 = −10.2 s = 8.4. Using the data, test the hypothesis that the blood pressure has decreased after the training.

### Bringing It Together

Use the following information to answer the next 10 exercises. Indicate which of the following choices best identifies the hypothesis test.
1. Independent group means, population standard deviations and/or variances known
2. Independent group means, population standard deviations and/or variances unknown
3. Matched or paired samples
4. Single mean
5. Two proportions
6. Single proportion