Description Usage Format Examples
10 Power Plant Pumps.
1 |
A data frame with 10 observations on the following 2 variables.
The length of the operation time.
The number of failures.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 | data(pumps)
pumps.data <- list(t = pumps$t, x = pumps$x, N = nrow(pumps))
pumps.model <- system.file("bugs/model/pumps.bug", package="rbugs")
file.show(pumps.model)
pumps.inits <- system.file("bugs/inits/pumps.txt", package="rbugs")
file.show(pumps.inits)
inits <- list(dget(pumps.inits))
parameters <- c("theta", "alpha", "beta")
## Not run:
pumps.sim <- rbugs(data = pumps.data, inits, parameters,
pumps.model, n.chains = 1, n.iter = 1000,
workingDir="~/tmp/",
useWine=TRUE)
## MCMC Analysis
library("coda")
pumps.mcmc <- rbugs2coda(pumps.sim)
summary(pumps.mcmc)
effectiveSize(pumps.mcmc)
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.