text
stringlengths
0
6.73k
and the effect of b is to add to the number of failures. In particular, setting a to | and
b to 1 resulted in a posterior with the equivalent of 803 + 1 successes and
(1574 — 803) + 1 failures, for a total of 1574 + 2 observations. From this view-
point, the total observations are the a + b provided by the prior plus the n provided
by the data, and this addition also gives the concentration parameter of the posterior
in terms of the concentration parameter of the prior.
How should we specify the prior distribution? The beta distribution is
convenient, because it is easy with this specification to find the posterior distribu-
tion, but what about a and b? Suppose we have asked 10 adults about the effect of
antibiotics on viruses, and it is reasonable to assume that the 10 are a random
sample. If 6 of the 10 say that antibiotics kill viruses, then we set a = 6 and
b=10-—6=4. That is, we have a beta distributed prior with parameters 6
and 4. Then the posterior distribution is beta with parameters 803 + 6 = 809 and
(1574 — 803) + 4 = 775. The posterior is the same as if we had started with a = 0
and b = 0 and observed 809 who said that antibiotics kill viruses and 775 who
--- Trang 793 ---
780 = cuarrer 14 Alternative Approaches to Inference
said no. In other words, observations can be incorporated into the prior and count
just as if they were part of the NSF survey. :
Life in the Bayesian world is sometimes more complicated. Perhaps the prior
observations are not of a quality equivalent to that of the survey, but we would still
like to use them to form a prior distribution. If we regard them as being only half as
good, then we could use the same proportions but cut the a and b in half, using 3 and
2 instead of 6 and 4. There is certainly a subjective element to this, and it suggests
why some statisticians are hesitant about using Bayesian methods. When everyone
can agree about the prior distribution, there is little controversy about the Bayesian
procedure, but when the prior is very much a matter of opinion people tend to
disagree about its value.
eee ~4=Assume a random sample X;,X2,...,X, from the normal distribution with known
variance, and assume a normal prior distribution for ju. In particular, consider the IQ
scores of 18 first- grade boys,
113° 108 140 113 11S 146 136 107 108 119 132 127 118
108 103 103 122 111
from the private speech data introduced in Example 1.2. Because the IQ has
a standard deviation of 15 nationwide, we can assume o = 15 is valid here. For
the prior distribution it is reasonable to use a mean of fo = 110, a ballpark figure
for previous years in this school. It is harder to prescribe a standard deviation for
the prior, but we will use ¢9 = 7.5. This is the standard deviation for the average of
four independent observations if the individual standard deviation is 15. As a result,
the effect on the posterior mean will turn out to be the same as if there were four
additional observations with average 110.
To compute the posterior distribution of the mean j1, we use Bayes’ theorem
ules. fie F(x1,42, ++ Xnl eg ()
PR f@i x2, malig (wdu
The numerator is
Fl, mle g(t) =e LL potlscitlet
ue v2n0 V2n0
x LL Stu te)? 08
V2n00
_ 1 eo SUle =H) 0? 4+ (nH)? (0 +H)? /08
GaP ona,
The trick here is to complete the square in the exponent, which yields
2
(—5/a7)(u— mi) +
where C does not involve ju and
Xi Li nx
2H +8 5+4
2 1 o oH oe oF
o=——, pw, =——__2 = ——_2
al nl al
eo oe a oe a
--- Trang 794 ---
14.4 Bayesian Methods 781
The posterior is then
= : L el 5/27) HI gC
72 3
Atheist = eat ae ee
# é| Se dy
(2n)"""a"a9 — J-co (22)? a1
The integral is 1 because it is the area under a normal pdf, and the part in front of the
integral cancels out, leaving a posterior distribution that is normal with mean jr; and
standard deviation o:
: =! syetiu-myt
(uly, x2... Xn) aaa e'
Notice that the posterior mean j1; is a weighted average of the prior mean
Ho and the data mean X, with weights that are the reciprocals of the prior variance
and the variance of X. It makes sense to define the precision as the reciprocal of
the variance because a lower variance implies a more precise measurement, and the
weights then are the corresponding precisions. Furthermore, the posterior variance
is the reciprocal of the sum of the reciprocals of the two variances, but this can
be described much more simply by saying that the posterior precision is the sum of
the prior precision plus the precision of x.
Numerically, we have
1 1 1 1 1 1 1
Fon’ a sys 7 O88 = Toa 3108
mx 18(118.28 110
a a 157 be 1S
= y= e677
at a jet 7s
The posterior distribution is normal with mean 4, = 116.77 and standard deviation
o, = 3.198. The mean ju; is a weighted average of ¥ = 118.28 and fy = 110, so py
is necessarily between them. As n becomes large the weight given to io declines,