Random Variables

advertisement
Random Variables
Definition
For a given sample sample space S of some experiment, a random
variable (rv) is any rule that associates a number with each outcome in
S. In mathematical language, a random variable is a function whose
domain is the sample space and whose range is the set of real numbers.
We use uppercase letters, such as X and Y to, denote random variables
and use lowercase letters, such as x and y , to denote some particular value
of the corresponding random variable. For example, X (s) = x means that
value x is associated with the oucome s by the rv X .
Liang Zhang (UofU)
Applied Statistics I
June 17, 2008
1/5
Random Variables
Examples:
1. Assume we toss a coin. Then S = {H, T}. We can define a rv X by
X (H) = 1 and X (T) = 0
2. A techincian is going to check the quality of 10 prodcuts. For each
product the outcome is either successful (S) or defective (D). Then we can
define a rv Y by
(
1, successful
Y =
0, defective
Definition
Any random variable whose only possible values are 0 abd 1 is called a
Bernoulli random variable.
Liang Zhang (UofU)
Applied Statistics I
June 17, 2008
2/5
Random Variables
More examples:
3. (Example 3.3) We are investigating two gas stations. Each has six gas
pumps. Consider the experiment in which the number of pumps in use at
a particular time of day is determined for each of the stations.
Define rv’s X , Y and U by
X = the total number of pumps in use at the two stations
Y = the difference between the number of pumps in use at station 1
and the number in use at station 2
U = the maximum of the numbers of pumps in use at the two stations
If this experiment is performed and s = (3, 4) results, then
X ((3, 4)) = 3 + 4 = 7, so we say that the observed value of X was x = 7.
Similarly, the observed value of Y would be y = 3 − 4 = −1, and the
observed value of U would be u = max(3, 4) = 4.
Liang Zhang (UofU)
Applied Statistics I
June 17, 2008
3/5
Random Variables
More examples:
4. Assume we toss a coin until we get a Head. Then the sample space
would be S = {H, TH, TTH, TTTH, . . . } If we define a rv X by X
X = the number we totally tossed
Then X ({H}) = 1, X ({TH}) = 2, X ({TTH}) = 3, . . . , and so on.
In this case, the random variable X can be any positive integer, which in
all is infinite.
5. Assume we are going to measure the length of 100 desks. Define the rv
Y by
Y = the length of a particular desk
Y can also assume infinitly possible values.
Liang Zhang (UofU)
Applied Statistics I
June 17, 2008
4/5
Random Variables
Definition
A dicrete random variable is an rv whose possible values either constitute
a finite set or else can be listed in an infinite sequence in which there is a
first element, a second element, and so on (“countably” infinite).
A random variable is continuous if both of the following apply:
1. Its set of possible values consists either of all numbers in a single
interval on the number line (possibly infinite in extent, e.g., (−∞, ∞) ) or
all numbers in a disjoint union of such intervals (e.g., [0, 10] ∪ [20, 30]).
2. No possible value of the variable has positive probability, that is,
P(X = c) = 0 for any possible value c.
Examples
Liang Zhang (UofU)
Applied Statistics I
June 17, 2008
5/5
Download