Continuous Uniform DistributionContinuous Uniform Distribution

Continuous distribution describes the stochastic experiment with infinite possible outcomes.
Continuous uniform distribution describes an experiment where all outcomes within the interval have an equal probability of occurring.
If the variable is uniformly distributed, we can use a geometrical approach to calculate probabilities.
Let's look at the example:

Consider a line segment of length 10 units. What is the probability of randomly selecting a point on the line segment such that the distance from the starting point to this point is between 3 and 7 units?

As a result, position or the point is uniformly distributed on the line with length 10. We can simply divide the length of the desired interval by the whole length of the segment.
We can also use .cdf() method on scipy.stats.uniform class to calculate the corresponding probability:

The first parameter of the .cdf() method determines the point at which we calculate probability; loc parameter determines the beginning of the segment, and scale determines the length of the segment.

The .cdf() method calculates the probability that an experiment's result falls into a certain interval: .cdf(interval_end) - .cdf(interval_start).
We will consider this method in more detail in Advanced Techniques in Probability and Statistics course.

Everything was clear?

Section 4. Chapter 1