A t-test is a statistical test of whether a sample mean differs from a hypothesised value, or whether two means differ, when the population variance is unknown and has to be estimated from the data. It is a standard tool of hypothesis testing, and its statistic follows Student’s t-distribution, published in 1908 by William Sealy Gosset under the pen name Student. The one-sample statistic is , where is the sample mean, the hypothesised mean, the sample standard deviation and the sample size.
There are three main forms. A one-sample test compares one mean with a fixed value; a two-sample test compares two independent groups, with pooled variance or in Welch’s version; and a paired test compares before-and-after measurements on the same units. The result is compared with critical values, or a p-value, under the null hypothesis. A z-test is used instead when the population standard deviation is known; as degrees of freedom rise, the t-distribution approaches the normal distribution.
Ref 1100001953