Robert_V._Hogg,_Joseph_W._McKean,_Allen_T._Craig

(Jacob Rumans) #1
3.3. TheΓ,χ^2 ,andβDistributions 179

command plots the density function over the interval (0,24):
x=seq(0,24,.1);plot(dchisq(x,10)~x).
Compute this line of code and locate the mean, quartiles, and median ofXon the
plot.
Example 3.3.3.The quantiles of theχ^2 -distribution are frequently used in statis-
tics. Before the advent of modern computation, tables of these quantiles were com-
piled. Table I in Appendix D offers a typicalχ^2 -table of the quantiles for the proba-
bilities 0. 01 , 0. 025 , 0. 05 , 0. 1 , 0. 9 , 0. 95 , 0. 975 , 0 .99 and degrees of freedom 1, 2 ,...,30.
As discussed, the R functionqchisqeasily computes these quantiles. Actually, the
following two lines of R code performs the computation of Table I.


rs=1:30; ps=c(.01,.025,.05,.1,.9,.95,.975,.99);
for(r in rs){print(c(r,round(qchisq(ps,r),digits=3)))}
Note that the code rounds the critical values to 3 places.

The following result is used several times in the sequel; hence, we record it as a
theorem.


Theorem 3.3.2.LetXhave aχ^2 (r)distribution. Ifk>−r/ 2 ,thenE(Xk)exists
and it is given by


E(Xk)=

2 kΓ

(r
2 +k

)

Γ

(r
2

) , ifk>−r/ 2. (3.3.8)

Proof:Notethat

E(Xk)=

∫∞

0

1
Γ

(r
2

)
2 r/^2

x(r/2)+k−^1 e−x/^2 dx.

Make the change of variableu=x/2 in the above integral. This results in

E(Xk)=

∫∞

0

1
Γ

(r
2

)
2 (r/2)−^1

2 (r/2)+k−^1 u(r/2)+k−^1 e−udu.

This simplifies to the desired result provided thatk>−(r/2).

Notice that ifkis a nonnegative integer, thenk>−(r/2) is always true. Hence,
all moments of aχ^2 distribution exist and thekth moment is given by (3.3.8).


Example 3.3.4. LetXhave a gamma distribution withα=r/2, whereris a
positive integer, andβ>0. Define the random variableY=2X/β. We seek the
pdf ofY. Now the mgf ofY is


MY(t)=E

(
etY

)
=E

[
e(2t/β)X

]

=

[
1 −
2 t
β

β

]−r/ 2
=[1− 2 t]−r/^2 ,

whichisthemgfofaχ^2 -distribution withrdegrees of freedom. That is,Yisχ^2 (r).
Free download pdf