Title: Random Variables and Distributions
1Random Variables and Distributions
2Basics of Random Variables and Probability
Distributions
- Consider again the experiment of tossing three
fair coins simultaneously. The sample space and
corresponding probabilities are given by - S HHH, HHT, HTH, THH, HTT, THT, TTH, TTT
- Probabilities 1/8, 1/8, 1/8, 1/8, 1/8, 1/8,
1/8, 1/8 - In a practical setting, H may represent
success of a medical operation T represents
failure. - In this situation we may not really be interested
in the elementary outcomes of S, but rather our
interest might be on the total number of H that
occurred in the outcome.
3Notion of a Random Variable
- When interest is on some numerical characteristic
of the outcomes of the experiment, then we are
led into consideration of random variables. - Definition A random variable, denoted by X, Y,
etc., is a function or procedure that assigns a
unique numerical value to each of the outcomes of
the experiment. The set of possible distinct
values of the variable is called its Range.
4A Simple Example
- In the coin-tossing experiment described earlier,
if we let X denote the random variable counting
the number of H in the outcome, then the values
of X associated with each of the 8 possible
outcomes are - X(HHH) 3, X(HHT) 2, X(HTH) 2, X(THH) 2,
X(HTT) 1, X(THT) 1, X(TTH) 1, X(TTT) 0 - Therefore, Range of X 0, 1, 2, 3.
- One of the advantages of dealing with random
variables instead of the elementary events of the
experiment is that we will be dealing with
numbers, which we could add, multiply, etc.,
instead of crude outcomes that we could not do
arithmetic operations.
5Types of Random Variables
- Random variables can be classified into either
discrete or continuous variables. - Discrete variables are those whose range has a
finite number or at most a countable number of
values while - Continuous variables are those whose range
contains an interval of the real line, hence has
an uncountable number of values. - The variable X in the example is clearly a
discrete random variable.
6Probability Distribution Function
- Definition Given a discrete random variable X
whose range is R x1, x2, x3, , its
probability function, denoted by p(x), is a
table, a graph, or a mathematical formula which
provides the probabilities for each of the
possible values in its range. In formal notation,
7Determining the Probability Function
- For a discrete random variable X, the value of
p(xj) is obtained by summing up the probabilities
of all the elementary events whose X-value is xj.
- A simple illustration makes this immediately
transparent. - For the variable X which counts the number of H
that occur in the toss of three fair coins, we
obtain the probability function as follows
8Probability Function for X in Example
- The range of X is R 0,1, 2, 3. We have
- p(0) P(X 0) P(TTT) 1/8 .125
- p(1) P(X 1) P(HTT) P(THT) P(TTH) 1/8
1/8 1/8 3/8 .375 - p(2) P(X 2) P(HHT) P(HTH) P(THH) 1/8
1/8 1/8 3/8 .375 - p(3) P(X 3) P(HHH) 1/8 .125
- In formula form
- p(x) (3Cx)(1/8), x0,1,2,3.
- In tabular and graphical forms the probability
function can be presented via
9Tabular/Graphical Presentation of the Probability
Function of X
10Properties and Utilities of Probability Functions
- Note that the sum of the probabilities, which are
all nonnegative, in a probability function equals
1. This is so because we take into account all
the possible outcomes, that is, the sample space,
and its probability is 1. That is, p(x) satisfies - p(x) gt 0 for all x, and ?all x p(x) 1.
- The shape of the distribution could be obtained
from the graph of the probability function. - For example, the probability distribution for the
variable X is symmetric with high points at the
values of 1 and 2.
11Utilities continued
- The probability function of a random variable
serves as a theoretical model of the population
of values of the variable, with this population
being the collection of the outcomes of the
experiment when it is repeated many, many, many
times. - Numerical characteristics of the probability
function, such as the mean, variance, and
standard deviation, will be called parameters. - The probability function can be used to compute
the probabilities that the variable takes values
in a certain set of interest. - For instance, in the example, P(X lt 2) p(0)
p(1) p(2) 1/8 3/8 3/8 7/8.
12Parameters of a Discrete Probability Distribution
- As mentioned earlier, a probability distribution
serves as a theoretical model of a population. - Characteristics of a probability distribution are
therefore called parameters, and they are usually
denoted by Greek letters. - We now discuss four important parameters of
discrete probability distributions. These are - Mean (?) and Median (?)
- Variance (?2) and Standard Deviation (?).
13Median of a Discrete Random Variable
- Given a discrete random variable X whose
probability distribution function is p(x), its
median, denoted by ?, is any value such that
14A Simple Example
- For the variable X denoting the number of H
that occur in the toss of three fair coins, we
therefore have - Mean ? (0)(1/8)(1)(3/8)(2)(3/8)(3)(1/8)
12/8 1.5. - For its median, we could take ? 1.5, since
notice that P(X lt 1.5) p(0) p(1) 1/8 3/8
0.5, and also, P(X gt 1.5) p(2) p(3) 1/8
3/8 0.5. - However, note that the median is not unique since
any value of ? between 1 and 2, exclusive, will
satisfy the definition of being a median.
15Interpretations
- As in the case of the sample statistics we have
the following interpretations - The mean, ?, serves as the center of gravity or
balancing point for the probability
distribution while - The median is a value that divides the
probability distribution into a 5050 split. - Other properties, like sensitivity of the mean to
extreme values also holds for these parameters.
16Variance of a Discrete Random Variable
- Given a discrete random variable X taking values
x1, x2, x3, whose probability distribution is
p(x), its variance, denoted by ?2, is given by
17Variance continued
- The first formula is called the definitional
formula, which indicates that the variance is the
mean of the squared deviations from the mean (?). - The second formula is called the computational or
the machine formula, and is easier to implement
in practice. - The variance is always nonnegative, and becomes
zero if and only if the random variable takes
only one value (we say in this case that it is a
degenerate variable). The larger the value of the
variance, the more variability in the
distribution. - The variance has squared units of measurements.
18Standard Deviation of a Discrete Random Variable
- Since the variance has squared units of
measurements, to obtain a measure of variation
whose units are the same as the variable, we
define the standard deviation (?) to be the
positive square root of the variance. - Formally, it is defined via
19Illustration of Computation of the Variance and
Standard Deviation
- Going back to the variable X which counts the
number of H in a toss of three fair coins, we
have, by recalling that ? 1.5 and using the
definition, that - ?2 Var(X) (0 - 1.5)2(1/8) (1 - 1.5)2(3/8)
(2 - 1.5)2(3/8) (3 - 1.5)2(1/8) (2.25)(.125)
(.25)(.375) (.25)(.375) (2.25)(.125)
0.75. - We could also use the computational formula to
get - ?2 Var(X) (0)2(.125) (1)2(.375)
(2)2(.375) (3)2(.125) - (1.5)2 0 .375
1.5 1.125 - 2.25 3 - 2.25 0.75. - Therefore, ? StdDev(X) (.75)(1/2) .866.
20Spreadsheet-Type Computation of the Parameters