Course contentsShow
← Data Science
Lesson 272 of 2,1458. Confidence IntervalsFree lesson

When to Use Z vs t

Decision rules for using z-intervals versus t-intervals based on sample size and known variance.

When to Use Z vs t

You'll learn: When to use the normal (z) distribution versus the t-distribution for constructing confidence intervals.

The Core Decision Rule

Now that you understand both confidence intervals and the t-distribution, you need to know which critical value to use. The choice between z and t depends on two key factors:

Factor 1: Population Standard Deviation

  • Use z if you know the population standard deviation (σ) — rare in real life
  • Use t if you must estimate σ from your sample (using sample standard deviation s) — almost always the case

Factor 2: Sample Size

Even when you don't know σ:

  • Use z if your sample size is very large (typically n ≥ 30), because the t-distribution converges to the normal distribution
  • Use t if your sample size is small (n < 30), because you need to account for extra uncertainty

The Practical Reality

In most real-world situations, you'll use the t-distribution because:

  1. You rarely know the true population standard deviation
  2. It's safer — the t-distribution has heavier tails, giving you wider (more conservative) confidence intervals
  3. Modern software defaults to t-intervals

Think of it like using safety margins: the t-distribution adds a "cushion" when you have less information (smaller sample) or must estimate variability from your data.

Key Takeaway: Use the t-distribution when estimating population standard deviation from your sample (almost always), and use z only when you truly know σ or have a very large sample where t ≈ z anyway.