Student’s distribution (also called Student’s t-distribution or just the t-distribution) with n degrees of freedom has density function given by
student(n,x) = |
| ⎛ ⎜ ⎜ ⎝ | 1 + |
| ⎞ ⎟ ⎟ ⎠ |
|
where recall the Gamma function is defined for x>0 by Γ(x) = ∫0∞e−ttx−1dx. If you enter
you will get
which can be numerically approximated by
which is
The cumulative distribution function for Student’s distribution with n degrees of freedom at a value x is student_cdf(n,x) = Prob(X ≤ x); if you enter
you will get
If you give student_cdf an extra argument, you will get the probability that the random variable lies between two values; student_cdf(n,x,y) = Prob(x ≤ X ≤ y). If you enter
you will get
The inverse distribution function for Student’s distribution with n degrees of freedom is computed with student_icdf(n,h); recall that this will return the value x with student_cdf(n,x) = h. If you enter
you will get
The UTPT (the Upper Tail Probability - T distribution) will compute Prob(X > x). If you enter
you will get