Ruud Wetzels
wetzels.ruud[at]gmail.com
Home - Research - Publications - Code - Links

WBDev Tutorial

Over the last decade, the popularity of Bayesian data analysis data in the empirical sciences has greatly increased. This is partly due to the availability of WinBUGS -a free and flexible statistical software package that comes with an array of predefined functions and distributions- allowing users to build complex models with ease.

For many applications in the psychological sciences, however, it is highly desirable to be able to define one's own distributions and functions. This functionality is available through the WinBUGS Development Interface (WBDev).

This tutorial illustrates the use of WBDev by means of concrete examples, featuring the Expectancy-Valence model of risky behavior in decision-making, and the shifted Wald distribution of response times in speeded choice.

All the code and data (zip) is available for download here.
You can download the corresponding tutorial from here.

The software

We use four bits of software:

[1]WinBUGS download
[2]WBDev download
[3]BlackBox download
[4]R download
[4.01] In our examples, we use R2WinBUGS. If you don't know how to install R2winBUGS, please read the following small tutorial (point [5]).

WBDev scripts for psychologists

In the table below you can find various examples of WBDev scripts that can be useful for psychologists. If you have a WBDev script and want to share it, feel free to send me an email so I can host it here.

Author(s) Description Article or Tutorial Files
Donkin, C. LBA model tutorial files
Vandekerckhove, J. & Tuerlinckx, F. Wiener diffusion model tutorial files
Wetzels, R. Expectancy Valence model tutorial files
Wetzels, R. shifted Wald distribution tutorial files

For WinBUGS examples that are relevant for cognitive modeling, you can visit Michael Lee's website. There you can find a coursebook on bayesian graphical modeling using WinBUGS. The book is a "work-in-progress" coming from graduate teaching, and is written by Michael Lee and EJ Wagenmakers.

For other examples and tutorials, you can visit the BUGS resources page.