Ripetizioni di Analisi
EN

Theory

Random variables and discrete distributions

From the probability mass function to choosing among the Bernoulli, binomial, geometric, Poisson, and hypergeometric distributions.

On this page
  1. Possible values and the probability mass function
  2. The cumulative distribution function and its jumps

Chapters 3 and 4 computed probabilities of events, such as “the item is defective”. In many problems, however, the quantity of interest is a number that depends on the outcome, such as the number of defective items in a sample or the number of calls that reach a switchboard in an hour. A number of this kind is called a random variable. This chapter deals with random variables that take isolated values, such as the counts , and for each one it computes the probability of every value, the mean value, and the spread around that value.

For example, each item produced by a machine is defective with probability , independently of the others, and an inspection examines 100 items. The probability of finding more than 4 defective items follows from the binomial distribution and is about ; the mean number of defective items is .

The expected value and the variance are the mean and the variance of the data in Chapter 2, with probabilities in place of relative frequencies. Chapter 6 deals with random variables that take every value in an interval, such as a duration; Chapter 7 computes probabilities that involve two or more random variables together and proves the rules for sums stated here. The binomial distribution returns in Chapter 8, because the proportion of successes in a sample is a binomial count divided by the sample size, and from there it enters the estimates and tests of Chapters 9-11.

Possible values and the probability mass function

1. Discrete random variable

Two coins are tossed. The four outcomes heads–heads, heads–tails, tails–heads, and tails–tails each have probability , and counting heads assigns a number to each outcome: , , , and .

Let be the sample space of an experiment, that is, the set of its outcomes (Chapter 3). A random variable is a rule that assigns a real number to each outcome in . The random variable is discrete when the values it takes with positive probability form a finite or countable set and their probabilities sum to . A countable set is an infinite set whose elements can be listed one after another, like the natural numbers (Chapter 1).

The discrete support is the set of values with strictly positive probability. For the number of heads, .

For a number , denotes the event made up of all outcomes to which assigns the value . In the example, contains heads–tails and tails–heads, so .

2. Probability mass function

For the number of heads in two tosses, , , and . Every other probability about follows from these three; for example, the probability of at least one head is .

The probability mass function of assigns to each real number the probability . The values are called masses. Outside the support the mass is zero; in the example, . The masses are nonnegative and sum to over the support.

For a set of values, the probability that falls in is the sum of the masses of the values in :

The formula holds because the events for distinct values are disjoint, so their probabilities add.

The way the total probability is shared among the values of is called the distribution of ; for a discrete random variable the distribution is given by the probability mass function. The most common distributions have names, and the notation , read ” has distribution…”, states the distribution of .

Normalizing a distribution

The number of faults reported by a counter takes the values , , and with masses , , and , respectively. Since these are all the possible values, the three masses sum to . Hence

The constant is positive, so all the masses are nonnegative and the table is a probability mass function. The values and lie in , so . The open endpoint excludes the mass at , whereas the closed endpoint includes the mass at .

x p_X(x) 123 O ⅛⅜½
The masses at 1 and 3 contribute to the probability of the interval. The mass at 0 is excluded.

Warning

A table of numbers that sum to is a probability mass function only if every number is nonnegative. The numbers , , and sum to , but the first is negative and therefore not a probability.

If the masses depend on a parameter, the sign of each individual mass must also be checked. The masses and sum to for every , but both are nonnegative only for .

The cumulative distribution function and its jumps

Cumulative distribution function

For the number of heads in two tosses, the probability of at most one head is . Also , because there are no possible values between and .

The cumulative distribution function of is , where is any real threshold. It is obtained by adding the masses of the values that do not exceed the threshold. Moreover, for every , the event is the union of the two disjoint events and , so the probability of an interval is the difference of two values of the cumulative distribution function:

The function is nondecreasing because, as increases, values with nonnegative mass are added. The value the function takes just before , that is, its left-hand limit, is written and equals the probability of the values strictly less than . Then

that is, the mass at is the height of the jump of the cumulative distribution function at . All the masses can therefore be recovered from the cumulative distribution function; indeed, tables of the most common distributions list the values of .

Reading a cumulative distribution function

Let be the number of requests observed over a short interval, with masses , , and at , , and , respectively. The cumulative distribution function equals below , from inclusive to exclusive, from inclusive to exclusive, and from onward. In particular, because the mass at is already included. By comparison, . The jump between the two levels is , equal to .

t F_X(t) -11231 O ¼¾
Cumulative distribution function with jumps at 0, 1, and 2

The probability is . Including the lower endpoint instead gives . The difference between the two answers is the mass at .

End of the free preview

The theory of this topic continues with 7 more sections

  1. Expected value, variance, and transformations
  2. Bernoulli trials and binomial counts
  3. Geometric waiting times and waiting for several successes
  4. The Poisson distribution
  5. Sampling without replacement
  6. Sums of counts and choosing a distribution
  7. Keep studying

Full access also includes the other 7 worked examples of this topic and the solutions of the 14 practice exercises.

Unlock Statistics and probability · €49

Read the first 3 worked examples in this chapter for free.

Report a mistake

Where:

Ripetizioni di Analisi

Keep studying

With a free account, you can pick up where you left off and see your progress next time you visit.

Sign up for free

Already have an account? Sign in

Contents