# Confidence Intervals

Let $x_1, \ldots, x_n$ be a sample from a normal population having unknown mean and variance. Let $\bar{x}$ be the average of the first n of them.

1. What is the distribution of $x_{n+1} - \bar{x}$?
2. If $\bar{x}=4$, give an interval that, with 90% confidence, will contain the value of $x_{n+1}$.

The distribution of $\bar{x}$ would be normal with mean equal to the population mean and standard deviation equal to the population standard deviation divided by $\sqrt{n}$. But how do we find the distribution of $x_{n+1}$?

We could say that the distribution of $x_1+x_2+\ldots+ x_{n+1}$ would be normal with mean $\bar{x}_{n+1}$ and variance $S^2_{n+1}$ (sample variance). Assuming that all of these variables are identically distributed and independent, we could say that the distribution of $x_{n+1}$ could be normal with $\bar{x}_{n+1}/(n+1)$ and $S^2_{n+1}/(n+1)$ using the central limit theorem.If this approach is correct how do I proceed from here?

$x_{n+1}$ itself is normally distributed with mean $\mu$ and variance $\sigma$ (two unknown numbers). Therefore, assuming it is also independent of the others, $x_{n+1}-\overline{x}$ is normally distributed. Recall a few useful rules:

• Expectation is linear
• $\operatorname{Var}[X+Y]=\operatorname{Var}[X]+\operatorname{Var}[Y]$ for independent $X,Y$
• $\operatorname{Var}[cX]=c^2\operatorname{Var}[X]$ for a real number $c$

Using these rules, you can calculate $E[x_{n+1}-\overline{x}]=0$ and $\operatorname{Var}[x_{n+1}-\overline{x}]=\sigma^2+\frac{n}{n^2} \sigma^2 = \frac{n+1}{n} \sigma^2$. This answers part 1.

If you knew $\sigma$, then you would use the above work to conclude that $x_{n+1}=\overline{x}+y$, where $y$ is a normal random variable independent of $x_1,\dots,x_n$ with mean zero and variance $\frac{n+1}{n} \sigma^2$. (Note that not knowing the mean enlarges the uncertainty a little bit: if we knew the mean then we would write $x_{n+1}=\mu+y$, where $y$ is normal with mean zero and variance $\sigma^2$.)

Again, if you knew $\sigma$, the above would allow you to construct a confidence interval for part 2. However, $\sigma$ is not known, so it needs to be estimated. Doing this estimation effectively enlarges the uncertainty somewhat. We correct this using the Student's $t$ distribution.

HINT

Here is the first couple of steps I would make. Assume the population's mean and variance are $\mu$ and $\sigma$.

Then $x_k \sim \mathcal{N}(\mu, \sigma^2)$ for any $k \in \mathbb{N}$. As you noted, it is not hard to see that $\bar{x}$ is normally distributed with mean $\mu$. Find the standard deviation.

Then subtract $x_{n+1} - \bar{x}$ to get a 0-mean random variable. What is the variance, what is it's distribution?

Hope you can take it from here...

• This works in the first part, but doesn't work at all in the second part, because the variance is unknown.
– Ian
Jan 26, 2016 at 17:20
• I think my mistake is deriving the distribution of x(n+1) from the distribution of the summation upto (n+1) rather than taking the given values(mu and sigma). When is the assumption, that I had made, valid? Is it only when the distribution of the summation is given? Jan 27, 2016 at 11:40
• @adhok i am not sure it is ever valid. $x_{n+1}$ is independent of $x_1, \ldots, x_n$ as stated, and so is independent of $\Sigma_n = \sum_{k=1}^n x_k$. If you are given the distribution of $\Sigma_n$ for arbitrary $n$, you could derive from there if you needed. Jan 27, 2016 at 15:12