Given a value t of Student's t statistic, is there an approximation or a fairly straightforward way to...
probability/t.distribution New
New entry, edited from material collected for the archive and not yet in a released version.
Problem
Given a value t of Student's t statistic, is there an approximation or a fairly straightforward way to calculate the corresponding alpha level (tail probability)? -- Jon Zeeff <zeeff@b-tech.UUCP>
Show solution
For ready-made FORTRAN:
Cooper, BE (1985). Algorithm AS3: The integral of Student's t
distribution, in _Applied_Statistics_Algorithms_, Griffiths and Hill,
eds. Ellis Horwood: Chichester, 38-39.
Hill, GW (1970). Algorithm 395: Student's t-distribution, CACM 13,
617-619.
If you prefer to roll your own, the approximation due to Wallace is
excellent. (1959, Annals of Mathematical Statistics 30:1121-1130). You
first convert to the normal (z) scale, and then use standard procedures
for normal tail areas (complementary error function). If the number of
degrees of freedom is n, and the observed t value is t, then the
transformation to z is given (in TeX) by:
$$z=\left(1-{2\sqrt{1-\exp(-s^2)}\over8n+3}\right)
\sqrt{n\log(1+t^2/n)},$$
where
$$s={0.368(8n+3)\over2\sqrt{n^2\log(1+t^2/n)}}.$$
-- Ronald A. Thisted (Dept. of Statistics, The University of Chicago)