The t distribution is symmetric but comparatively flatter (see the solid line in the graph below) than the standard normal distribution (the dashed line below). The shape of particular t-distribution is determined by the degrees of freedom (df) = . When the sample mean $ \bar{X}$ and the sample standard deviation $ S$ are obtained from the data of $ n$ observations, it is often assumed that the test statistic $ T = \displaystyle\frac{\bar{X}-\mu}{S/\sqrt{n}}$ has the t-distribution with $ df = n-1$ degrees of freedom with true population mean $ \mu$. If the true standard deviation $ \sigma$ is known, use df = +Inf (the infinity $ +\infty$).

We can calculate the critical region corresponding to the level $ \alpha$.

Level (p-value) $ \alpha =$
Right-tailed region $ T > t_{\alpha,df} =$
Two-sided region $ \vert T\vert > t_{\alpha/2,df} =$
Left-tailed region $ T < -t_{\alpha,df} =$

The appropriateness of this calculation can be ensured if (a) the sample distribution is approximately normal (the use of QQ plot is recommended), or (b) the sample size $ n$ is adequately large (as a rule of thumb it is desirable to have $ n \ge 30$).

Conversely when the statistic $ T =$ is given, we can find the corresponding $ \alpha$ so that the value $ T$ belongs to the critical region, and call it p-value.