Course contentsShow
← Machine Learning and Deep Learning
Lesson 87 of 3,5381. Mathematical Foundations for Machine LearningFree lesson

Confidence Intervals

Constructing interval estimates that contain the true parameter with specified probability.

Confidence Intervals

What you'll learn: How to construct an interval around your estimate that captures the true population parameter with a known level of certainty.

Why Interval Estimates Matter

Up to now, you've learned about point estimation—calculating a single number (like a sample mean) to estimate a population parameter. But a single number doesn't tell you how uncertain that estimate is. That's where confidence intervals come in.

A confidence interval is a range of values constructed from your sample data that likely contains the true population parameter. Instead of saying "the average is 50," you say "I'm 95% confident the true average lies between 48 and 52."

The Core Idea

Think of it like catching fish with a net. You cast your net (collect a sample), and you want to be confident you've caught the true fish (parameter). A wider net catches more reliably, but a narrower net is more precise. A 95% confidence interval means if you repeated this process 100 times with different samples, about 95 of those intervals would contain the true parameter.

The interval is typically constructed as:

Estimate ± (Critical Value × Standard Error)

  • Estimate: Your point estimate (e.g., sample mean)
  • Critical Value: Comes from a probability distribution (often Normal or t-distribution), determines your confidence level
  • Standard Error: Measures sampling variability (related to variance and sample size)

Thanks to the Central Limit Theorem, for large samples, many estimators follow a Normal distribution, making confidence interval construction straightforward.

Interpretation Caution

A 95% confidence interval does not mean "there's a 95% probability the parameter is in this specific interval." The parameter is fixed; the interval is random. It means 95% of such intervals constructed this way will capture it.

Key Takeaway: Confidence intervals quantify estimation uncertainty by providing a range that contains the true parameter with specified confidence, combining point estimates with sampling variability.