confint() — Confidence interval

A give-or-take range where the true average probably sits.

mean ± t · (s/√n)

Key idea

Definition

the sample mean
the t critical value for your confidence level
the sample standard deviation
the sample size

In plain words

Like guessing 'the candy jar has about 50 sweets, give or take 6.' The interval is your honest fuzzy guess instead of one exact number.

Where you'd use it

Worked example 12

From a sample of heights, a 95% interval gives a low-to-high range that probably contains the true average height.

Frequently asked questions

What does a 95% confidence interval mean?
If you repeated the study, 95% of such intervals would contain the true value — not "95% chance it’s in this one".