[R] dgamma in WinBUGS and JAGS (rjags)

Seyed Reza Jafarzadeh srjafarzadeh at gmail.com
Thu Jul 3 10:45:39 CEST 2008


It was a documentation error that got fixed in the latest version
(June 30, 2008) of the JAGS manual.

Reza



On Wed, Jun 25, 2008 at 6:20 PM, Ben Bolker <bolker at ufl.edu> wrote:
> Seyed Reza Jafarzadeh <srjafarzadeh <at> gmail.com> writes:
>
>>
>> Hello,
>>
>> In WinBUGS 1.4 manual
>> (http://www.mrc-bsu.cam.ac.uk/bugs/winbugs/manual14.pdf), the gamma
>> density is presented as dgamma(r,mu) where r and mu are the shape and
>> rate parameters, respectively. In JAGS (rjags) manual version 1.0.2,
>> May 9, 2008 (http://www-fis.iarc.fr/~martyn/software/jags/jags_user_manual.pdf),
>> on page 26 the gamma density is presented as dgamma(mu,r) instead of
>> dgamma(r,mu). Since JAGS uses the BUGS language, I was wondering if
>> this is a typo or it is in fact different from WinBUGS.
>>
>
>  I don't know, but I would suggest (1) trying a couple of little
> simulations to try it out for yourself -- for example with
> the following BUGS code
>
> mu <- 1
> r <- 1
> x ~ dgamma(mu,r)
>
>  and see what the distribution looks like.
>
> and (2) e-mailing Martyn Plummer, the author (since it seems
> likely that this is a documentation bug, he probably would
> like to hear from you)
>
>  Ben Bolker
>
> ______________________________________________
> R-help at r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.
>



More information about the R-help mailing list