Greetings, Is it possible to use evidence in a Winbug model? For example, a random variable in a model has been observed, and I'd like to update the other variables in the model, pretty much the same update perfomed in tools like Smile, or other inference software.

Gibbs sampling is supposed to use observed values in full conditional distribution when there observations/evidence are entered into the model, but I am not sure if Winbugs allows this.


edit to clarify:

The winbug documentation says a stochastic node is a data node if it has been observed, but a stochastic node is described via a distribution as in some_var ~ dbin(theta,n) if it has been observed, then I'd like to tell this to winbugs without losing the semantics of the stochastic node, expressing something like "some_var has this distribution, and it has been observed to have this particular value". so how do I do that? by declaring some_var as I've done above and than setting a value to it as in some_var = 5 ? Would that express what I want to express?

In this case, in each observation of a node in a bayesian network, I'd need to redefine the winbugs model, (quite likely) replacing initial values of the unobserved nodes with the outcomes of the previous simulation.

In short, I'm trying to understand how to perform updates on a Bayesian network similar to message passing in exact inference, but using Gibbs sampling instead, via Winbugs.

  • $\begingroup$ It takes only the most casual acquaintance with WinBUGS to answer this question as stated (i.e., does WinBUGS actually process data? Yes, of course), so I'm wondering whether some other question is intended. $\endgroup$ – whuber Mar 22 '11 at 20:09
  • $\begingroup$ whuber, you are right, I could not express myself clear enough. I've edited the question. $\endgroup$ – mahonya Mar 23 '11 at 10:13

Of course it's possible to use evidence from observations in WinBUGS! Try working through any of the examples in the documentation that comes with the program to see how.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.