t.test() — One-sample t-test

Checks if your group’s average matches a number you guessed.

t.test(x, mu = 0)

Key idea

Definition

the sample mean
the hypothesised mean
the sample standard deviation
the sample size
the test statistic

Where you'd use it

Frequently asked questions

What does the p-value tell me?
How surprising the data would be if the null were true. Small p (< 0.05) is evidence against it.
Which t-test do I need?
One-sample (vs a number), two-sample (two groups), or paired (matched pairs).