A SAS interface for Bayesian Analysis with WinBUGS
2005-11-28    Zhang, Z., McArdle, J. J., Wang, L., & Hamagami, F.
Using WinBUGS inside SAS for Bayesian Analysis: With an Example of Fitting a Growth Curve Model

NEW An example to use SAS and OpenBUGS is available now. Click here to see it.

Bayesian methods are becoming very popular despite some practically difficulties in implementation. To assist in the practical application of Bayesian methods, we show how to implement Bayesian analysis with WinBUGS as part of a standard set of SAS routines. This procedure is first explained step by step by fitting a multiple regression model and a linear growth curve model. A third example is also provided to demonstrate how to iteratively run WinBUGS inside SAS for Monte Carlo simulation studies. The SAS codes used in the current study can also accommodate many other models with only slight modification. This interface can be of practical benefit in many aspects of Bayesian methods because it allows the SAS users to benefit from the implementation of Bayesian inference procedure such as Gibbs sampling and it also allows the WinBUGS user to benefit from the data transformation in SAS and the flexibility of using WinBUGS.

NOTE: Many codes were messed up during the publishing process, especially ' is replaced by \ and " is replaced by \\`. You are recommended to use the draft. DOWNLOAD THE DRAFT

Related SAS codes.

1. Linear regression

2. Factor analysis

Rodney Sparapani's SAS Macros for BUGS website has more information on how to use the SAS macros specifically.

Go to his website : http://ww2.mcw.edu/pcor/bugs/

To cite this study (thanks), use

Zhang, Z., McArdle, J. J., Wang, L., & Hamagami, F. (2008). A SAS interface for Bayesian analysis with WinBUGS. Structural Equation Modeling, 15(4), 705-728.

@ARTICLE{Zhang2008SEM,

author = {Zhang, Z. and McArdle, J. J. and Wang, L. and Hamagami, F.},
title = {A SAS interface for Bayesian analysis with WinBUGS},
journal = {Structural Equation Modeling},
year = {2008},
volume = {15},
pages = {705--728},
number = {4},
url = {http://www.psychstat.org/us/article.php/44.htm}
}

Editor: johnny