## Q. What is a random variable?

The formal mathematical definition of a random variable is “a function from a sample space to real numbers.”  This definition, while concise, can also be confusing.

Start by defining the sample space as all possible outcomes of an experiment. Suppose a coin is flipped two times. The sample space would be {HH, TH, HT, TT} where H represents heads and T represents tails. The sample space by itself is difficult to analyze because there are no real numbers to work with. This is why random variables are used; they create a numerical outcome for the experiment.

For the experiment above, random variables could be assigned as X = the number of heads or Y = the number of tails. Both random variables can take the values 0, 1, or 2. The random variable is the function that takes the outcomes of the experiment and describes a relevant numerical result.

Random variables are denoted with upper case letters and the values the random variables assume are denoted with lowercase letters.

### Topics

• Last Updated Apr 16, 2021
• Views 3