Saturday, May 25, 2019

Published 7:06 PM by with 0 comment

Understanding Confidence Intervals

Confidence intervals are confusing. I tried putting together a visualization that explains a valid interpretation of them.
In case you aren't familiar, here's the wikipedia entry on confidence intervals.

Demonstrated interpretation


If you repeat the procedure N times, the percent of calculated 90% confidence intervals that contain the true population parameter would tend toward 90%.

I attempted to visualize this one. The animation below generates 100 random numbers from a normal distribution centered at 0 (0 is the true population parameter here). It then calculates the confidence interval. It does this hundreds of times and calculates the percentage of confidence intervals that contained 0. For an 80% confidence interval, that should be ~80%. For an 85% one, that should be 85%...

You can select the confidence interval to change it.

Confidence Interval

Bad interpretations that this demo clears up

  1. It is clear from the visualization that the X% confidence interval does not contain X% of the points.
  2. It is clear from the visualization that the X% confidence interval is not the entire range of plausible values. The fact that some of the calculated confidence intervals do not contain 0 shows this pretty conclusively.

      edit

0 comments:

Post a Comment