Skip to content

Commit cc40b16

Browse files
authored
Update README.md
1 parent 533b93b commit cc40b16

File tree

1 file changed

+43
-4
lines changed

1 file changed

+43
-4
lines changed

JuliaBUGS/README.md

Lines changed: 43 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,49 @@
22
[![Stable](https://img.shields.io/badge/docs-stable-blue.svg)](https://TuringLang.github.io/JuliaBUGS.jl/stable)
33
[![Dev](https://img.shields.io/badge/docs-dev-blue.svg)](https://TuringLang.github.io/JuliaBUGS.jl/dev)
44

5-
A modern implementation of the [BUGS](https://en.wikipedia.org/wiki/WinBUGS) probabilistic programming language in Julia.
5+
**JuliaBUGS.jl** is a modern, high-performance implementation of the [BUGS](https://en.wikipedia.org/wiki/WinBUGS) probabilistic programming language in [Julia](https://julialang.org/). It brings the familiar BUGS modelling syntax into the Julia ecosystem, enabling Bayesian inference with speed, flexibility, and seamless integration with the scientific computing ecosystem in Julia.
66

7-
For a working example, follow this [link](https://turinglang.org/JuliaBUGS.jl/stable/example).
7+
---
88

9-
Try [DoodleBUGS](https://turinglang.org/JuliaBUGS.jl/DoodleBUGS/) for a browser-based interface for drawing BUGS models.
9+
## Why JuliaBUGS?
1010

11-
See also, [JAGS](https://sourceforge.net/p/mcmc-jags/code-0/ci/default/tree/) and [Nimble](https://r-nimble.org/).
11+
- **BUGS syntax** — write models using standard BUGS notation.
12+
13+
- **Julia performance** — leverage Julia’s speed and just-in-time (JIT) compilation.
14+
15+
- **Interoperability with Julia ecosystem** — works smoothly with MCMC algrorithms from [Turing.jl](https://turinglang.org/) and the broader Julia PPL ecosystem.
16+
17+
---
18+
19+
## Quick Start
20+
21+
A simple example model:
22+
23+
```julia
24+
using JuliaBUGS, Random, AbstractMCMC
25+
26+
model = JuliaBUGS.@bugs"""
27+
model {
28+
for (i in 1:N) {
29+
y[i] ~ dnorm(mu, tau)
30+
}
31+
mu ~ dnorm(0, 0.001)
32+
tau ~ dgamma(0.1, 0.1)
33+
}
34+
"""
35+
36+
posterior = compile(model, (; N = 10, y = randn(10)))
37+
38+
chain = AbstractMCMC.sample(rng, posterior, JuliaBUGS.IndependentMH(), 1000)
39+
```
40+
41+
For a complete walkthrough, see the [example](https://turinglang.org/JuliaBUGS.jl/stable/example).
42+
43+
---
44+
45+
## **Related Tools**
46+
47+
- [**DoodleBUGS**](https://turinglang.org/JuliaBUGS.jl/DoodleBUGS/) — a browser-based interface for drawing BUGS models.
48+
- [**RJuliaBUGS**](https://mateusmaiads.github.io/rjuliabugs/) — an R interface to JuliaBUGS.
49+
50+
For alternative BUGS-family tools, see [JAGS](https://sourceforge.net/p/mcmc-jags/code-0/ci/default/tree/) and [Nimble](https://r-nimble.org/).

0 commit comments

Comments
 (0)