Chapter Contents
Chapter Contents
Previous
Previous
Next
Next
Functions

BAYESACT Call

computes posterior probabilities that observations are contaminated with a larger variance.

Syntax

CALL BAYESACT(k,s,df,\alpha_1, ... ,\alpha_n,y_1, ... ,y_n,
 \beta_1, ... ,\beta_n,p_0);

where

kis the contamination coefficient, where k \geq 1.
sis an independent estimate of \sigma, where s\geq0.
dfis the number of degrees of freedom for s, where df\geq0.
\alpha_iis the prior probability of contamination for the ith observation in the sample, where i = 1, ... ,n and n is the number of observations in the sample. Note that 0\leq\alpha_i\leq1.
yiis the ith observation in the sample, where i = 1, ... ,n and n is the number of observations in the sample. When the BAYESACT call is used to perform a Bayes analysis of designs (see "Description" below), the yis are estimates for effects.
\beta_iis the variable that contains the returned posterior probability of contamination for the ith observation in the sample, where i = 1, ... ,n and n is the number of observations in the sample.
p0is the variable that contains the posterior probability that the sample is uncontaminated.

Description

The BAYESACT call computes posterior probabilities (\beta_i)that observations in a sample are contaminated with a larger variance than other observations and computes the posterior probability (p0) that the entire sample is uncontaminated.

Specifically, the BAYESACT call assumes a normal random sample of n independent observations, with a mean of 0 (a centered sample) where some of the observations may have a larger variance than others:

{Var}(y_i) = \{ \sigma^2 & {with probability } 1-\alpha_i \ k^2\sigma^2 & {with probability } \alpha_i.

where i = 1, ... ,n. The parameter k is called the contamination coefficient. The value of \alpha_i is the prior probability of contamination for the ith observation. Based on the prior probability of contamination for each observation, the call gives the posterior probability of contamination for each observation and the posterior probability that the entire sample is uncontaminated.

Box and Meyer (1986) suggest computing posterior probabilities of contamination for the analysis of saturated orthogonal factorial designs. Although these designs give uncorrelated estimates for effects, the significance of effects cannot be tested in an analysis of variance since there are no degrees of freedom for error. Box and Meyer suggest computing posterior probabilities of contamination for the effect estimates. The prior probabilities (\alpha_i) give the likelihood that an effect will be significant, and the contamination coefficient (k) gives a measure of how large the significant effect will be. Box and Meyer recommend using \alpha =0.2 and k=10, implying that about 1 in 5 effects will be about 10 times larger than the remaining effects. To adequately explore posterior probabilities, examine them over a range of values for prior probabilities and a range of contamination coefficients.

If an independent estimate of \sigma is unavailable (as is the case when the yis are effects from a saturated orthogonal design), use 0 for s and df in the BAYESACT call. Otherwise, the call assumes s is proportional to the square root of a \chi^2 random variable with df degrees of freedom. For example, if the yis are estimated effects from an orthogonal design that is not saturated, then use the BAYESACT call with s equal to the estimated standard error of the estimates and df equal to the degrees of freedom for error.

From Bayes' theorem, the posterior probability that yi is contaminated is

\beta_i(\sigma)=\frac{\alpha_if(y_i;0,k^2\sigma^2) }
 {\alpha_if(y_i;0,k^2\sigma^2) + (1-\alpha_i)f(y_i;0,\sigma^2) }

for a given value of \sigma, where f(x;\mu,\sigma) is the density of a normal distribution with mean \mu and variance \sigma^2.

The probability that the sample is uncontaminated is

p=\prod_{i=1}^n(1-\beta_i(\sigma))

Posterior probabilities that are independent of \sigma are derived by integrating \beta_i(\sigma) and p over a noninformative prior for \sigma. If an estimate of \sigma is available (when df>0), it is appropriately incorporated. Refer to Box and Meyer (1986) for details.

Examples

The statements
   data;
      retain post1-post7 postnone;
      call bayesact(10,0,0,
             0.2,   0.2,   0.2,   0.2,   0.2,     0.2,   0.2,
         -5.4375,1.3875,8.2875,0.2625,1.7125,-11.4125,1.5875,
           post1, post2, post3, post4, post5,   post6, post7,
         postnone);
   run;

return the following posterior probabilities:

   POST1      0.42108
   POST2      0.037412
   POST3      0.53438
   POST4      0.024679
   POST5      0.050294
   POST6      0.64329
   POST7      0.044408
   POSTNONE   0.28621

The probability that the sample is uncontaminated is 0.28621. A situation where this BAYESACT call would be appropriate is a saturated 27 design in 8 runs, where the estimates for main effects are as shown in the function above (-5.4375, 1.3875, . . . , 1.5875).

Chapter Contents
Chapter Contents
Previous
Previous
Next
Next
Top
Top

Copyright © 1999 by SAS Institute Inc., Cary, NC, USA. All rights reserved.