INTERACTIVE ANIMATION: CONFIDENCE INTERVAL

 

The following animation illustrates the concept of "Confidence Interval".

 

Parameters can be adjusted only before starting the animation, or in the "Reset" mode.

 

In this animation, samples are repetitively drawn from a "mother" normal distribution (green curve). The distribution of the sample average is shown too for information (red curve), but it is not directly involved in the animation.

For each sample, the sample average is calculated. The animation then calculates the proportion of samples for which the population mean was actually inside the confidence interval. This proportion should converge towards the user preset confidence level.

 

 

 

 

 

 

 

 

The confidence interval is always centered on the sample mean. Its width depends on :

    * The variance of the mother population,

    * The number of observations in each sample,

    * The user preset confidence level.

 

Notice that for a given confidence level, the width of the interval decreases as :

    * The variance of the mother distribution decreases (and therefore, the variance of the "daughter" distribution too),

    * The number of observations increases (and therefore the variance of the "daughter" distribution decreases).

 

This confirms the intuitive idea that the true mean (of the mother distribution) is spotted with all the more certainty that the variance of this distribution is low, and that the sample is large.

 

Notice that for a given variance of the mother population, and a given number of observations, the width of the confidence interval goes up with the imposed confidence level : you can be almost sure that the mean is in a given region only if the region is large.

________________________________

 

In real life, you have only one sample, that is, only one draw of the above animation, and therefore only one confidence interval. But you can determine the probability that this interval actually contains the mean of the distribution (if you know for a fact that the distribution is normal, and if you know its variance, and these are big "if"s).

Download this Glossary