Learn practical skills, build real-world projects, and advance your career

MA2102

Probability and Statistics

Lecture-11

Types of Random Variables

Let XX be a random variable defined on (Ω,F,P)(\Omega,\mathscr{F},P), and (R,B,PX)(\mathbb{R},\mathscr{B},P^X) be induced probability space by XX, then CDFCDF FXF_X will be either continuous everywhere or it will have countably many (finite/countably infinite) (jump)discontinuities where the sum of jump lengths at the point of discontinuities always \le1. We will use these properties to classify random variables.

import matplotlib.pyplot as plt
import numpy as np
x=np.linspace(-10,10,100)
fig, ax = plt.subplots(3,1,figsize=(15,10))
# Continuous type example CDF Plot
ax[0].plot(x,1/2+(1/np.pi)*np.arctan(x),color='blue')
ax[0].set_title("(i) Continuous type",fontsize=10,color='blue')

# Discrete type exmaple CDF Plot
x1=[0,1,2,3]
y1=[0,1/8,1/2,7/8]
x2=[0,1,2,3]
y2=[1/8,1/2,7/8,1]
ax[1].scatter(x1,y1,facecolors='none', edgecolors='black')
ax[1].scatter(x2,y2,facecolors='black', edgecolors='black')
ax[1].set_xlim(-2,5)
ax[1].plot([-2,0],[0,0],color='purple')
ax[1].plot([0,1],[1/8,1/8],color='purple')
ax[1].plot([1,2],[1/2,1/2],color='purple')
ax[1].plot([2,3],[7/8,7/8],color='purple')
ax[1].plot([3,5],[1,1],color='purple')
ax[1].set_title("(ii) Descrete type",fontsize=10,color='purple')

# Mixture Type example CDF Plot
ax[2].plot([-3,1],[0,0],color='navy')
xx=np.linspace(1,2,50)
ax[2].plot(xx,(xx-1)*(xx-1)/2,color='navy')
ax[2].plot([2,3],[1/2,1/2],color='navy')
ax[2].plot([3,5],[1,1],color='navy')
ax[2].scatter([3],[1/2],facecolors='none', edgecolors='black')
ax[2].scatter([3],[1],facecolors='black', edgecolors='black')
ax[2].plot([3,5],[1,1],color='navy')
ax[2].set_title("(iii) Mixture type",fontsize=10,color='navy')
# ax[0].set_xticks([])

plt.show()
Notebook Image

Definition: A random variable XX is said to be of discrete type if it's CDFCDF has countably many discontinuities with sum of jump at the point of discontinuities exactly equals to 11.