Discrete Random Variables
Random variables
The process of drawing a sample randomly is a random experiment and any variable measured in the sample is a random variable because the values taken by the variable in the individuals of the sample are a matter of chance.
Definition - Random variable. A random variable
The set of values that the variable can assume is called the range and is represented by
In essence, a random variable is a variable whose values come from a random experiment, and every value has a probability of occurrence.
Example. The variable
Types of random variables
There are two types of random variables:
-
Discrete. They take isolated values, and their range is numerable. Example. Number of children of a family, number of smoked cigarettes, number of subjects passed, etc.
-
Continuous. They can take any value in a real interval, and their range is non-numerable. Example. Weight, height, age, cholesterol level, etc.
The way of modelling each type of variable is different. In this chapter we are going to study how to model discrete variables.
Probability distribution of a discrete random variable
As values of a discrete random variable are linked to the elementary events of a random experiment, every value has a probability.
We can also accumulate probabilities the same way that we accumulated sample frequencies.
The range of a discrete random variable and its probability function is known as probability distribution of the variable, and it is usually presented in a table
The same way that the sample frequency table shows the distribution of values of a variable in the sample, the probability distribution of a discrete random variable shows the distribution of values in the whole population.
Example. Let
According to this, the probability distribution of
Population statistics
The same way we use sample statistics to describe the sample frequency distribution of a variable, we use population statistics to describe the probability distribution of a random variable in the whole population.
The population statistics definition is analogous to the sample statistics definition, but using probabilities instead of relative frequencies.
The most important are 1:
Definition - Discrete random variable mean The mean or the expectec value of a discrete random variable
Definition - Discrete random variable variance and standard deviation The variance of a discrete random variable
The standard deviation of a random variable
Example. In the random experiment of tossing two coins the probability distribution is
The main population statistics are
Discrete probability distribution models
According to the type of experiment where the random variable is measured, there are different probability distributions models. The most common are
- Discrete uniform
- Binomial
- Poisson
Discrete uniform distribution
When all the values of a random variable
Definition - Discrete uniform distribution
Observe that
The mean and the variance are
Example. The variable that measures the outcome of rolling a dice follows a discrete uniform distribution model
Binomial distribution
Usually the binomial distribution corresponds to a variable measured in a random experiment with the following features:
- The experiment consist in a sequence of
repetitions of the same trial. - Each trial is repeated in identical conditions and produces two possible outcomes known as Success or Failure.
- The trials are independent.
- The probability of Success is the same in all the trials and is
.
Under these conditions, the discrete random variable
Definition - Binomial distribution
Observe that
The mean and the variance are
Example. The variable that measures the number of heads after tossing 10 coins follows a binomial distribution model
According to this,
- The probability of getting 4 heads is
- The probability of getting 2 or less heads is
- And the expected number of heads is
Example. In a population there are a 40% of smokers. The variable
Poisson distribution
Usually the Poisson distribution correspond to a variable measured in a random experiment with the following features:
- The experiment consists of observing the number of events occurring in a fixed interval of time or space. For instance, number of births in a month, number of emails in one hour, number of red blood cells in a volume of blood, etc.
- The events occur independently.
- The experiment produces the same average rate of events
for every interval unit.
Under these conditions, the discrete random variable
Definition - Poisson distribution
Observe that
The mean and the variance are
Example. In a city there are an average of 4 births every day. The random variable
According to this,
- The probability that there are 5 births in a day is
- The probability that there are less than 2 births in a day is
- The probability that there are more than 1 birth a day is
Approximation of Binomial by Poisson distribution
The Poisson distribution can be obtained from the Binomial distribution when the number of trials repetition tends to infinite and the probability of Success tends to zero.
Law or rare events. The Binomial distribution
In practice, this approximation can be used for
Example. A vaccine produce an adverse reaction in 4% of cases. If a sample of 50 persons are vaccinated, what is the probability of having more than 2 persons with an adverse reaction?
The variable that measures the number of persons with an adverse reaction in the sample follows a Binomial distribution model
-
To distinguish population statistics from sample statistics we use Greek letters. ↩︎