This lesson describes how to create a confidence interval for the difference between two population means.

**Checking Conditions**

Before we can create a confidence interval for the difference between two population means, we first need to make sure the following conditions are met to ensure that our confidence interval will be accurate:

**Random:**A random sample or random experiment should be used to obtain the data for both samples.**Normal:**The sampling distribution of the difference between sample means needs to be approximately normal. This is true if the two populations we are studying are both normal or if our sample size is sufficiently large (typically n ≥ 30)**Independent:**The two samples are independent.

The formula to find a confidence interval for the difference between two population means is:

(x_{1} – x_{2}) +/- (z critical value) * (√s^{2}_{1} / n_{1} + s^{2}_{2} / n_{2})

where x_{1} is the mean of sample 1, x_{2 } is the mean of sample 2, s^{2}_{1} is the variance of sample 1, n_{1} is the sample size of sample 1, s^{2}_{2} is the variance of sample 2, and n_{2} is the sample size of sample 2.

Let’s walk through an example of how to find a confidence interval for the difference between two population means.

**Example: Confidence Interval for the Difference Between Two Population Means**

Researchers want to know whether a new diet helps people lose weight. 100 randomly assigned people are assigned to group 1 and put on the new diet. Another 100 randomly assigned people are assigned to group 2 and are kept on their normal diet. After three months, the mean weight loss for group 1 was 8 pounds with a standard deviation of 2 pounds and the mean weight loss for group 2 was 6 pounds with a standard deviation of 3 pounds.

**Construct a 95% confidence interval for the difference in mean weight loss of group 1 – group 2.**

**Solution:**

**Step 1: Find the difference between the two means.**

x_{1} – x_{2} =8 – 6 = **2**

**Step 2: Find the z critical value.**

Since we are using a 95% confidence level, we need to look up (1 – 0.95)/2 = .05/2 = .025 in the body of the z table and find the corresponding z value. It turns out to be **-1.96**.

**Step 3: Find the standard deviation of the difference between the two means.**

√s^{2}_{1} / n_{1} + s^{2}_{2} / n_{2} = √2^{2} / 100 + 3^{2} / 100 = **0.36**

**Step 4: Plug all of the numbers we just found into the confidence interval formula.**

(x_{1} – x_{2}) +/- (z critical value) * (√s^{2}_{1} / n_{1} + s^{2}_{2} / n_{2})

(2) +/- (-1.96)*(.36)

2 +/- .7056 =** (1.2944 , 2.7056)**

The 95% confidence interval for the difference in mean weight loss (in pounds) of group 1 – group 2 is** (1.2944, 2.7056)**