0% found this document useful (0 votes)
45 views

Cumulative Distribution Function

The document discusses the cumulative distribution function (CDF) and how it can be used to describe the distribution of both discrete and continuous random variables. The CDF of a random variable X is defined as FX(x) = P(X ≤ x) for all values of x. For a discrete random variable, the CDF is a step function that jumps up by the probability mass at each value in the variable's range. The CDF completely describes the distribution of a discrete random variable.

Uploaded by

yes
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
45 views

Cumulative Distribution Function

The document discusses the cumulative distribution function (CDF) and how it can be used to describe the distribution of both discrete and continuous random variables. The CDF of a random variable X is defined as FX(x) = P(X ≤ x) for all values of x. For a discrete random variable, the CDF is a step function that jumps up by the probability mass at each value in the variable's range. The CDF completely describes the distribution of a discrete random variable.

Uploaded by

yes
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 5

24/10/2020 Cumulative Distribution Function

3.2.1 Cumulative Distribution Function


The PMF is one way to describe the distribution of a discrete random variable. As we will see later on, PMF cannot be defined for continuous random variables. The
cumulative distribution function (CDF) of a random variable is another method to describe the distribution of random variables. The advantage of the CDF is that it can be
defined for any kind of random variable (discrete, continuous, and mixed).

Definition 3.10
The cumulative distribution function (CDF) of random variable X is defined as

FX (x) = P (X ≤ x),  for all x ∈ R.

Note that the subscript X indicates that this is the CDF of the random variable X . Also, note that the CDF is defined for all x ∈ R. Let us look at an example.

Example 3.9

I toss a coin twice. Let X be the number of observed heads. Find the CDF of X .

Solution
1
Note that here X ∼ Binomial(2,
2
). The range of X is RX = {0, 1, 2} and its PMF is given by

1
PX (0) = P (X = 0) = ,
4

1
PX (1) = P (X = 1) = ,
2

1
PX (2) = P (X = 2) = .
4

To find the CDF, we argue as follows. First, note that if x < 0, then

FX (x) = P (X ≤ x) = 0,  for x < 0.

Next, if x ≥ 2,

FX (x) = P (X ≤ x) = 1,  for x ≥ 2.

Next, if 0 ≤ x < 1,

1
FX (x) = P (X ≤ x) = P (X = 0) = ,  for 0 ≤ x < 1.
4

Finally, if 1 ≤ x < 2,

1 1 3
FX (x) = P (X ≤ x) = P (X = 0) + P (X = 1) = + = ,  for 1 ≤ x < 2.
4 2 4

Thus, to summarize, we have

⎧0 for x < 0



⎪ 1
for 0 ≤ x < 1
4
FX (x) = ⎨
3
⎪ for 1 ≤ x < 2

⎪ 4


1 for x ≥ 2

Note that when you are asked to find the CDF of a random variable, you need to find the function for the entire real line. Also, for discrete random variables,
we must be careful when to use "<" or "≤". Figure 3.3 shows the graph of FX (x). Note that the CDF is flat between the points in RX and jumps at each
1 3
value in the range. The size of the jump at each point is equal to the probability at that point. For, example, at point x = 1, the CDF jumps from 4
to 4
.
3 1 1 3
The size of the jump here is 4

4
=
2
which is equal to PX (1). Also, note that the open and closed circles at point x = 1 indicate that FX (1) =
4

and not 1
.
4

https://www.probabilitycourse.com/chapter3/3_2_1_cdf.php 1/5
24/10/2020 Cumulative Distribution Function

Fig.3.3 - CDF for Example 3.9.

In general, let X be a discrete random variable with range RX = {x 1 , x 2 , x 3 , . . . }, such that x 1 < x 2 < x 3 <. . . Here, for simplicity, we assume that the
range RX is bounded from below, i.e., x 1 is the smallest value in RX . If this is not the case then FX (x) approaches zero as x → −∞ rather than hitting zero.
Figure 3.4 shows the general form of the CDF, FX (x), for such a random variable. We see that the CDF is in the form of a staircase. In particular, note that the CDF
starts at 0; i.e.,FX (−∞) = 0. Then, it jumps at each point in the range. In particular, the CDF stays flat between x k and x k+1 , so we can write

FX (x) = FX (x k ),  for x k ≤ x < x k+1 .

The CDF jumps at each x k . In particular, we can write

FX (x k ) − FX (x k − ϵ) = PX (x k ),  For ϵ > 0 small enough.

Thus, the CDF is always a non-decreasing function, i.e., if y ≥ x then FX (y) ≥ FX (x) . Finally, the CDF approaches 1 as x becomes large. We can write

lim FX (x) = 1.
x→∞

https://www.probabilitycourse.com/chapter3/3_2_1_cdf.php 2/5
24/10/2020 Cumulative Distribution Function

Fig.3.4 - CDF of a discrete random variable.

Note that the CDF completely describes the distribution of a discrete random variable. In particular, we can find the PMF values by looking at the values of the jumps in
the CDF function. Also, if we have the PMF, we can find the CDF from it. In particular, if RX = {x 1 , x 2 , x 3 , . . . }, we can write

FX (x) = ∑ PX (x k ).

xk ≤x

Now, let us prove a useful formula.

For all a ≤ b, we have

P (a < X ≤ b) = FX (b) − FX (a) (3.1)

To see this, note that for a ≤ b we have

P (X ≤ b) = P (X ≤ a) + P (a < X ≤ b).

Thus,

FX (b) = FX (a) + P (a < X ≤ b).

Again, pay attention to the use of "<" and "≤" as they could make a difference in the case of discrete random variables. We will see later that Equation 3.1 is true for all
types of random variables (discrete, continuous, and mixed). Note that the CDF gives us P (X ≤ x) . To find P (X < x) , for a discrete random variable, we can
simply write

P (X < x) = P (X ≤ x) − P (X = x) = FX (x) − PX (x).

Example 3.10
Let X be a discrete random variable with range RX = {1, 2, 3, . . . } . Suppose the PMF of X is given by

1
PX (k) =  for k = 1, 2, 3, . . .
k
2

a. Find and plot the CDF of X , FX (x).


b. Find P (2 < X ≤ 5).
c. Find P (X > 4).

Solution
First, note that this is a valid PMF. In particular,
https://www.probabilitycourse.com/chapter3/3_2_1_cdf.php 3/5
24/10/2020 Cumulative Distribution Function
∞ ∞
1
∑ PX (k) = ∑ = 1 (geometric sum)
k
k=1 k=1
2

a. To find the CDF, note that


For x < 1, FX (x) = 0.
1
For 1 ≤ x < 2, FX (x) = PX (1) =
2
.
1 1 3
For 2 ≤ x < 3, FX (x) = PX (1) + PX (2) = + = .
2 4 4

In general we have

For 0 < k ≤ x < k + 1,

FX (x) = PX (1) + PX (2)+. . . +PX (k)

k
1 1 1 2 −1
= + +. . . + = .
k k
2 4 2 2

Figure 3.5 shows the CDF of X .

Fig.3.5 - CDF of random variable given in Example 3.10.

b. To find P (2 < X ≤ 5), we can write

https://www.probabilitycourse.com/chapter3/3_2_1_cdf.php 4/5
24/10/2020 Cumulative Distribution Function
31 3 7
P (2 < X ≤ 5) = FX (5) − FX (2) = − = .
32 4 32

Or equivalently, we can write

1 1 1 7
P (2 < X ≤ 5) = PX (3) + PX (4) + PX (5) = + + = ,
8 16 32 32

which gives the same answer.

c. To find P (X > 4), we can write

15 1
P (X > 4) = 1 − P (X ≤ 4) = 1 − FX (4) = 1 − = .
16 16

← previous
next →

https://www.probabilitycourse.com/chapter3/3_2_1_cdf.php 5/5

You might also like