Download The Cumulative Distribution Function for a Random Variable

Survey
yes no Was this document useful for you?
   Thank you for your participation!

* Your assessment is very important for improving the workof artificial intelligence, which forms the content of this project

Document related concepts

Inductive probability wikipedia , lookup

Simulated annealing wikipedia , lookup

Probability amplitude wikipedia , lookup

Law of large numbers wikipedia , lookup

Transcript
The Cumulative Distribution Function for a Random Variable \
Each continuous random variable \ has an associated probability density function (pdf)
0 ÐBÑ. It “records” the probabilities associated with \ as areas under its graph. More
precisely,
“the probability that a value of \ is between + and ,” œ T Ð+ Ÿ \ Ÿ ,Ñ œ '+ 0 ÐBÑ .B.
For example,
$
T Ð" Ÿ \ Ÿ $Ñ
œ '" 0 ÐBÑ .B
_
T Ð$ Ÿ \Ñ œ T Ð$ Ÿ \  _Ñ œ '$ 0 ÐBÑ .B
"
T Ð\ Ÿ  "Ñ œ T Ð  _  \ Ÿ  "Ñ œ '_ 0 ÐBÑ .B
,
i) Since probabilities are always between ! and ", it must be that 0 ÐBÑ !
,
(so that '+ 0 ÐBÑ .B can never give a “negative probability”), and
ii) Since a “certain” event has probability ",
_
T Ð  _  \  _Ñ œ " œ '_ 0 ÐBÑ .B œ total area under the graph of 0 ÐBÑ
The properties i) and ii) are necessary for a function 0 ÐBÑ to be the pdf for some random
variable \Þ
We can also use property ii) in computations: since
_
$
_
'_
0 ÐBÑ .B œ '_ 0 ÐBÑ  '$ 0 ÐBÑ .B œ "
$
_
T Ð\ Ÿ $Ñ œ '_ 0 ÐBÑ .B œ "  '$ 0 ÐBÑ .B œ "  T Ð\ $Ñ
The pdf is discussed in the textbook.
There is another function, the cumulative distribution function (cdf) which records the
same probabilities associated with \ , but in a different way. The cdf J ÐBÑ is defined by
J ÐBÑ œ T Ð\ Ÿ BÑ.
J ÐBÑ gives the “accumulated” probability “up to B.” We can see immediately how the
pdf and cdf are related:
J ÐBÑ œ T Ð\ Ÿ BÑ œ '_ 0 Ð>Ñ .> (since “B” is used as a variable in the
upper limit of integration, we use some
other variable, say “>”, in the integrand)
B
Notice that J ÐBÑ ! (since it's a probability), and that
a) lim J ÐBÑ œ lim '_ 0 Ð>Ñ .> œ '_ 0 Ð>Ñ .> œ " and
BÄ_
BÄ_
B
_
b) lim J ÐBÑ œ lim ' 0 Ð>Ñ .> œ ' 0 Ð>Ñ .> œ !, and that
B
BÄ_
BÄ_ _
_
_
c) J w ÐBÑ œ 0 ÐBÑ (by the Fundamental Theorem of Calculus)
Item c) states the connection between the cdf and pdf in another way:
the cdf J ÐBÑ is an antiderivative of the pdf 0 ÐBÑ (the particular antiderivative
where the constant of integration is chosen to make the limit in a) true)
and therefore
T Ð+ Ÿ \ Ÿ ,Ñ œ '+ 0 ÐBÑ .B œ J ÐBÑl,+ œ J Ð,Ñ  J Ð+Ñ œ T Ð\ Ÿ ,Ñ  T Ð\ Ÿ +Ñ
,
________________________________________________________________________
Example: Suppose \ has an exponential density function. As discussed in class,
0 ÐBÑ œ œ
!
-/-B
B!
(where - œ ." Ñ
B !
If B !, '_ 0 Ð>Ñ .> œ '! 0 Ð>Ñ .> œ '! -/-> .> œ  /-> lB! œ "  /-B , so
B
B
J ÐBÑ œ œ
B
!
"  /-B
B!
B !
If \ has mean . œ $, say, then - œ
"
.
œ "$ .
If we want to know T Ð\ Ÿ %Ñ, we can either compute
%
%
'_
0 ÐBÑ .B œ '_ " /Ð"Î$ ÑB .B ¸ !Þ($'%!$, or (now that we have the formula for J ÐBÑ
$
we can simply compute J Ð$Ñ œ "  /Ð"Î$Îц% œ "  /%Î$ ¸ !Þ($'%!$Þ
(The graphs of 0 ÐBÑ and J ÐBÑ are shown on the last page before exercises. In the figure,
notice the values of lim J ÐBÑ and lim J ÐBÑ ÑÞ
BÄ_
BÄ_
________________________________________________________________________
Example: If \ is a normal random variable with mean . œ ! and standard deviation
#
#
B
5 œ "ß then its pdf is 0 ÐBÑ œ È"#1 /B Î# , and its cdf J ÐBÑ œ È"#1 '_ /> Î# .>.
#
Because there is no “elementary” antiderivative for /> Î# , its not possible to find an
#
B
“elementary” formula for J ÐBÑ. However, for any B, the value of È"#1 '_ /> Î# .> can
be estimated, so that a graph of J ÐBÑ can be drawn. (See figure on the last page before
exercises.)
Example: More generally, probability calculations involving a normal random variable
\ are computationally difficult because again there's no elementary formula for the
cumulative distribution function J ÐBÑ  that is, an antiderivative for the probability
den=ity function À
0 ÐBÑ œ
"
5 È#1
#
/ÐB.Ñ Î#5
#
Therefore it's not possible to find an exact value for
T Ð+ Ÿ \ Ÿ ,Ñ œ '+
,
"
5 È#1
#
#
/ÐB.Ñ Î#5 .B œ J Ð,Ñ  J Ð+Ñ
Suppose \ is a normal random variable with mean . œ "Þ* and standard deviation
5 œ "Þ(. If we want to find T Ð  $ Ÿ \ Ÿ #Ñ, we need to estimate
"
Ð"Þ(ÑÈ#1
'2 /ÐB"Þ*Ñ# Î#Ð"Þ(Ñ# .B œ J Ð#Ñ  J Ð  $ÑÞ
3
This can be done with Simpson's Rule. However, such calculations are so important that
the TI83-Plus Calculator has a built in way to make the estimate:
Punch keys 28. HMWX V
Choose item 2 on the menu: normalcdf
On the screen you see
normalcdf Ð
Fill in
normalcdf Ð  $ß #ß "Þ*ß "Þ(Ñ
and the TI-83 gives the approximate value of the integral above: !Þ&#"480
The general syntax for the
command is
If you enter only
then the TI-83 assumes . œ !ß 5 œ "
as the default values
normalcdf (lowerlimit,upperlimit,.ß 5 )
normalcdf Ðlowerlimit,upperlimitÑ
Note that using the values for .ß 5 example given above:
T Ð.  5 Ÿ \ Ÿ .  5 Ñ
T Ð .  #5 Ÿ \ Ÿ .  # 5 Ñ
T Ð .  $5 Ÿ \ Ÿ .  $ 5 Ñ
¸ normalcdf ÐÞ#ß $Þ'ß "Þ*ß "Þ(Ñ ¸ !Þ')#(
¸ normalcdf Ð  "Þ&ß &Þ$ß "Þ*ß "Þ(Ñ ¸ !Þ*&%&
¸ normalcdf Ð  $Þ#ß (ß "Þ*ß "Þ(Ñ ¸ !Þ**($
In fact (as may have been mentioned in class) these probabilities come out the same for
any normal random variable, no matter what the values of . and 5 : for example, the
probability that any normal random variable takes on a value between „ one standard
deviation of its mean is ¸ 0.6827Þ
Exercises:
1. A certain “uniform” random variable \ has pdf 0 ÐBÑ œ œ
"Î& # Ÿ B Ÿ (
!
otherwise.
a) What is T Ð! Ÿ \ Ÿ $Ñ?
b) Write the formula for its cdf J ÐBÑ
c) What is J Ð$Ñ  J Ð!Ñ ?
2. A certain kind of random variable as density function 0 ÐBÑ œ
"
1 Ð"  B# Ñ .
a) What is T Ð\  "Ñ?
b) Write the formula for its cdf J ÐBÑ
c) Write a formula using J ÐBÑ that gives the answer to part a). Check that it
agrees with your numerical answer in a).