This morning officer Jones is deployed to NY state highway 17A to monitor the speeding vehicles. Its been a rather damp morning; his computer has recorded the speeds of only 20 vehicles so far.
He is nicely tucked away in a corner where jammers cannot find him. With no vehicles in sight, he started playing with the data.
He computes the average vehicle speed.
Mean vehicle speed miles per hour.
But officer Jones is a variance freak. He computes the sample variance and the sample standard deviation.
The sample variance is 5.9 , and the sample standard deviation is 2.43 mph.
“I wonder how large this deviation can get,” thought officer Jones.
Can we answer his question?
The answer lies in knowing the confidence interval on the variance.
We now know how to construct the confidence interval on the true mean based on the sample.
The interval is the confidence interval of the population mean .
The basis for this is the idea that we can find an interval that has a certain probability of containing the truth.
In other words, a confidence interval for a parameter is an interval [l, u] that has the property .
We can apply the same logic to the variance. Office Jones is wondering about the true standard deviation or true variance . He is wondering if he can derive the interval for the true variance given his limited data.
How can we derive the confidence interval on the variance?
Remember what we did for deriving the confidence interval on the mean. We investigated the limiting distribution of , the sample mean and used the probability statement on this distribution to derive the end-points, the upper and lower confidence limits.
Let’s do the same thing here.
What is the limiting distribution for sample variance?
.
.
.
Those who followed lesson 73 carefully will jump up to say that it is related to the Chi-square distribution.
follows a Chi-square distribution with degrees of freedom.
Okay, no problem. We will do it again.
Let’s take the equation of the sample variance and find a pattern in it.
Move the over to the left-hand side and do some algebra.
Let’s divide both sides of the equation by .
The right-hand side now is the sum of squared standard normal distributions.
; sum of squares of standard normal random variables.
As we learned in lesson 53, if there are n standard normal random variables, , their sum of squares is a Chi-square distribution with n degrees of freedom.
Its probability density function is for and 0 otherwise.
Since we have
follows a Chi-square distribution with degrees of freedom.
Depending on the degrees of freedom, the distribution of looks like this.
Smaller sample sizes imply lower degrees of freedom and the distribution will be highly skewed; asymmetric.
Larger sample sizes or higher degrees of freedom will tend the distribution to symmetry.
We can now apply the probability equation and define a confidence interval for the true variance .
is between 0 and 1. You know that a 95% confidence interval means , and a 99% confidence interval means .
and are the lower and upper critical values from the Chi-square distribution with degrees of freedom.
The main difference here is that the Chi-square distribution is not symmetric. We should calculate both the lower limit and the upper limit that correspond to a certain level of probability.
Take for example, a 95% confidence interval. We need and , the quantiles that yield a 2.5% probability in the right tail and 2.5% probability in the left tail.
and
Going back to the probability equation
With some rearrangement within the inequality, we get
The interval is called the confidence interval of the population variance .
We can get the square roots of the confidence limits to get the confidence interval on the true standard deviation.
The interval is called the confidence interval of the population standard deviation .
Let’s now go back to the data and construct the confidence interval on the variance and the standard deviation.
Officer Jones has a sample of 20 vehicles. . The sample variance is 5.9 and the sample standard deviation s is 2.43.
Since n = 20, follows a Chi-square distribution with 19 degrees of freedom. The lower and upper critical values at the 95% confidence interval and are 8.90 and 32.85.
You must be wondering about the tediousness in computing these quantiles each time there is a sample.
That problem is solved for us. Like the t-table, the upper tail probabilities of the Chi-square distribution for various degrees of freedom are tabulated in the Chi-square table.
You can get them from any statistics textbooks, or a simple internet search on “Chi-square table” will do. Here is an example.
The first column is the degrees of freedom. The subsequent columns are the computed values for , the right tail probability.
For our example, say we are interested in the 95% confidence interval, we look under df = 19 and identify as the lower limit that yields a probability of 2.5% on the left tail, and as the upper limit that yields a probability of 2.5% on the right tail.
Substituting these back into the confidence interval equation, we get
The 95% confidence interval for the true variance is [3.41, 12.59].
If we take the square root of these limits, we get the 95% confidence interval for the true standard deviation.
The 95% confidence interval for the true variance is [1.85 3.54].
So, to finally answer office Jones’ question, at the 95% confidence level, the deviation in vehicle speed can be as large as 3.54 mph and as low as 1.85 mph. The interval itself is random. As you know by now the real interpretation is:
If we have a lot of different samples, and if we compute the 95% confidence intervals for these samples using the sample variance and the Chi-square critical limits from the Chi-square distribution, in the long-run, 95% of these intervals will contain the true value of .
A few vehicles must have sneaked by in the short run.
If you find this useful, please like, share and subscribe.
You can also follow me on Twitter @realDevineni for updates on new lessons.