1. Concepts & Definitions
1.1. Continous random distribution of probability
1.2. Normal distribution of probability
1.3. Standard normal distribution of probability
1.4. Inverse standard normal distribution
1.6. Inverse Student's T distribution
2. Problem & Solution
2.1. Weight, dimension, and value per HS6
2.2. How to fit a distribution
2.3. Employing standard deviation
2.4. Total time spent in a system
Let's remake the section 1.4 numerical example, but instead of using the inverse standard normal distribution, employ the inverse Student's T distribution. This means how to find interval limits given the total percentage P(a ≤ z ≤ b) of the population that should be covered by it.
Examples of finding the following quantities:
• Find interval limits [a, b] with that holds 90% of the values that follow a Student's T distribution with parameters T(0, 1).
Another way to see this question is that the b upper limit of the interval [a, b] is chosen in a manner that P(t ≤ b) = 1 − α/2 = 0.95 holds as shown in the next figure.
Use a Python code to find the following quantities:
• Find interval limits [a, b] with that holds 90% of the values that follow a Student's T distribution with parameters T(40, 8): P(a ≤ t ≤ b) = 0.90.
• Find interval limits with 90% of the values for the Student's T distribution with parameters T(40, 1).
The following code shows the probability of the numerical example employing PPF as the inverse of Student's T distribution using t.cdf command.
Now, it is possible to estimate the interval of values considering Student's T distribution as T(40, 8).
from scipy.stats import t
prob = 0.90
half_alpha = (1 - prob)/2
mean = 40
std = 8
deg_f = 10
a = t.ppf(half_alpha, df = deg_f, loc=mean, scale=std)
b = t.ppf(1-half_alpha, df = deg_f, loc=mean, scale=std)
print('[',a,', ',b,']')
[ 25.500311017514125 , 54.499688982485864 ]
And, it is possible to estimate the interval of values considering Student's T distribution as T(40, 1).
mean = 40
std = 1
deg_f = 10
a = t.ppf(half_alpha, df = deg_f, loc=mean, scale=std)
b = t.ppf(1-half_alpha, df = deg_f, loc=mean, scale=std)
print('[',a,', ',b,']')
[ 38.18753887718927 , 41.81246112281073 ]
The previous complete code is available in the following link:
https://colab.research.google.com/drive/142Opmonx36rqjSqS9qrVl3sipNrWOpNu?usp=sharing