0% found this document useful (0 votes)
114 views4 pages

4.1 - Probability Density Functions (PDFS) and Cumulative Distribution Functions (CDFS) For Continuous Random Variables - Statistics LibreTexts

1) Probability density functions (PDFs) describe the probabilities of continuous random variables, which have uncountably many possible values. A PDF must be non-negative, piecewise continuous, and have an integral of 1. 2) The probability that a continuous random variable takes on a value in an interval is given by the integral of the PDF over that interval. 3) A cumulative distribution function (CDF) gives the probability that a continuous random variable is less than or equal to each value. It is calculated by integrating the PDF from negative infinity to that value.

Uploaded by

Raavi Tiwari
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
114 views4 pages

4.1 - Probability Density Functions (PDFS) and Cumulative Distribution Functions (CDFS) For Continuous Random Variables - Statistics LibreTexts

1) Probability density functions (PDFs) describe the probabilities of continuous random variables, which have uncountably many possible values. A PDF must be non-negative, piecewise continuous, and have an integral of 1. 2) The probability that a continuous random variable takes on a value in an interval is given by the integral of the PDF over that interval. 3) A cumulative distribution function (CDF) gives the probability that a continuous random variable is less than or equal to each value. It is calculated by integrating the PDF from negative infinity to that value.

Uploaded by

Raavi Tiwari
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 4

4.

1: Probability Density Functions (PDFs) and Cumulative Distribution Functions (CDFs)


for Continuous Random Variables
Probability Density Functions (PDFs)
Recall that continuous random variables have uncountably many possible values (think of intervals of real numbers).
Just as for discrete random variables, we can talk about probabilities for continuous random variables using density
functions.

Definition 4.1.1
The probability density function (pdf), denoted f , of a continuous random variable X satisfies the following:
1. f (x) ≥ 0 , for all x ∈ R
2. f is piecewise continuous

3. ∫ f (x) dx = 1

−∞
a

4. P (a ≤ X ≤ b) = ∫ f (x) dx

The first three conditions in the definition state the properties necessary for a function to be a valid pdf for a
continuous random variable. The fourth condition tells us how to use a pdf to calculate probabilities for continuous
random variables, which are given by integrals the continuous analog to sums.

Example 4.1.1
Let the random variable X denote the time a person waits for an elevator to arrive. Suppose the longest one would
need to wait for the elevator is 2 minutes, so that the possible values of X (in minutes) are given by the interval [0, 2] .
A possible pdf for X is given by

⎧ x,

for 0 ≤ x ≤ 1

f (x) = ⎨ 2 − x, for 1 < x ≤ 2




0, otherwise

The graph of f is given below, and we verify that f satisfies the first three conditions in Definition 4.1.1:
1. From the graph, it is clear that f (x) ≥ 0 , for all x ∈ R .
2. Since there are no holes, jumps, asymptotes, we see that f (x)  is (piecewise) continuous.
3. Finally we compute:

∞ 2 1 2

∫ f (x) dx = ∫ x dx = ∫ x dx + ∫ (2 − x) dx

−∞ 0 0 0

= 1

Figure 1: Graph of pdf for X , f (x)


So, if we wish to calculate the probability that a person waits less than 30 seconds (or 0.5 minutes) for the elevator to
arrive, then we calculate the following probability using the pdf and the fourth property in Definition 4.1.1:

0.5 0.5

P (0 ≤ X ≤ 0.5) = ∫ f (x) dx = ∫ x dx

0 0

= 0.125

Note that, unlike discrete random variables, continuous random variables have zero point probabilities, i.e., the
probability that a continuous random variable equals a single value is always given by 0. Formally, this follows from
properties of integrals:

P (X = a) = P (a ≤ X ≤ a) = ∫ f (x) dx = 0.

Informally, if we realize that probability for a continuous random variable is given by areas under pdf's, then,
since there is no area in a line, there is no probability assigned to a random variable taking on a single value. This
does not mean that a continuous random variable will never equal a single value, only that we do not  assign any
probability to single values for the random variable. For this reason, we only talk about the probability of a
continuous random variable taking a value in an INTERVAL, not at a point. And whether or not the endpoints of the
interval are included does not affect the probability. In fact, the following probabilities are all equal:

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

= P (a ≤ X < b) = P (a < X ≤ b) = ∫ f (x)

dx

Cumulative Distribution Functions (CDFs)


Recall Definition 3.2.2, the definition of the cdf, which applies to both discrete and continuous random variables. For
continuous random variables we can further specify how to calculate the cdf with a formula as follows. Let X have
pdf f , then the cdf F is given by

F (x) = P (X ≤ x) = ∫ f (t) dt, for x ∈ R.

−∞

In other words, the cdf for a continuous random variable is found by integrating the pdf. Note that the Fundamental
Theorem of Calculus implies that the pdf of a continuous random variable can be found by differentiating the cdf.
This relationship between the pdf and cdf for a continuous random variable is incredibly useful.

Relationship between PDF and CDF for a Continuous Random Variable


Let X be a continuous random variable with pdf f and cdf F .
By definition, the cdf is found by integrating the pdf:

F (x) = ∫ f (t) dt

−∞

By the Fundamental Theorem of Calculus, the pdf can be found by differentiating the cdf:

d
f (x) = [F (x)]
dx

Example 4.1.2
Continuing in the context of Example 4.1.1, we find the corresponding cdf. First, let's find the cdf at two possible
values of X , x = 0.5 and x = 1.5 :

0.5 0.5
2 0.5
t ∣
F (0.5) = ∫ f (t) dt = ∫ t dt = ∣ = 0.125
2 ∣0
−∞ 0

1.5 1 1.5
2 1
t ∣
F (1.5) = ∫ f (t) dt = ∫ t dt + ∫ (2 − t) dt = ∣
2 ∣0
−∞ 0 1

2 1.5
t ∣
+ (2t − )∣ = 0.5 + (1.875 − 1.5)
2 ∣
1

= 0.875

Now we find F (x) more generally, working over the intervals that f (x) has different formulas:

x
x

for x < 0 : F (x) = ∫ 0 dt = 0


for x < 0 : F (x) = ∫ 0 dt =
−∞

x
2 x −∞ 2
t ∣ x
for 0 ≤ x ≤ 1 : F (x) = ∫ t dt = ∣ = x
2 ∣0 2
0

for 0 ≤ x ≤ 1 : F (x)
1 =x ∫ t dt =
2 1
t ∣
for 1 < x ≤ 2 : F (x) = ∫ t dt + ∫ (2 − t) dt = ∣
0 2 ∣0
0 1

1
2 x 2
t ∣ x
+ (2t − ) ∣ = 0.5 + (2x − )
2 ∣1 2
for 1 < x ≤ 2 : F (x) = ∫ t dt
2
x
− (2 − 0.5) = 2x − −1
0
2
x
2
t
for x > 2 : F (x) = ∫ f (t) dt = 1
+ (2t − )
−∞ 2

Putting this altogether, we write F as a piecewise function and Figure 2 gives its graph:

⎧ 0, for x < 0



⎪ x2
⎪ , for 0 ≤ x ≤ 1
2
F (x) = ⎨
2
x
⎪ 2x − − 1, for 1 < x ≤ 2

⎪ 2



1, for x > 2

Figure 2: Graph of cdf in Example 4.1.2

Recall that the graph of the cdf for a discrete random variable is always a step function. Looking at Figure 2 above, we
note that the cdf for a continuous random variable is always a continuous function.
Percentiles of a Distribution

Definition 4.1.2
The (100p)th percentile (0 ≤ p ≤ 1 ) of a probability distribution with cdf F  is the value π such that p

F (πp ) = P (X ≤ πp ) = p.

To find the percentile π of a continuous random variable, which is a possible value of the random variable, we are
p

specifying a cumulative probability p and solving the following equation for π :


p

πp

∫ f (t)dt = p
−∞

Special Cases: There are a few values of p for which the corresponding percentile has a special name.
Median or 50  percentile: π = μ = Q , separates probability (area under pdf) into two equal halves
th
.5 2

1st Quartile or 25  percentile: π = Q , separates 1  quarter (25%) of probability (area) from the rest
th
.25 1
st

3rd Quartile or 75  percentile: π = Q , separates 3  quarter (75%) of probability (area) from the rest
th
.75 3
rd

Example 4.1.3
Continuing in the context of Example 4.1.2, we find the median and quartiles.
median: find π , such that F (π ) = 0.5 ⇒ π = 1 (from graph in Figure 1)
.5 .5 .5

1st quartile: find Q = π , such that F (π ) = 0.25 . For this, we use the formula and the graph of the cdf in Figure
1 .25 .25

2:

2
π
.25 −
−−
= 0.25 ⇒ Q1 = π.25 = √0.5 ≈ 0.707
2

3rd quartile: find Q 3 = π.75 , such that F (π .75 ) = 0.75 . Again, use the graph of the cdf:

2
π
.75
2π.75 − − 1 = 0.75 
2

⇒  (using Quadratic Formula) Q3 = π.75



4 − √2
= ≈ 1.293
2

This page titled 4.1: Probability Density Functions (PDFs) and Cumulative Distribution Functions (CDFs) for Continuous Random
Variables is shared under a not declared license and was authored, remixed, and/or curated by Kristin Kuter.

You might also like