if (FALSE) {
data("GasolineYield")
eg1 <- zoib(yield ~ temp + as.factor(batch)| 1, data=GasolineYield,
joint = FALSE, random = 0, EUID = 1:nrow(d),
zero.inflation = FALSE, one.inflation = FALSE,
n.iter = 1600, n.thin = 2, n.burn=100, seeds=c(1,2),n.chain=2)
xnew <- data.frame(temp = c(205, 218), batch = factor(c(1, 2), levels = 1:10))
ypred <- pred.zoib(eg1, xnew)
data("BiRepeated")
eg2 <- zoib(y1|y2 ~ x|1|x, data= BiRepeated, n.response=2,
random=1, EUID= BiRepeated$id,
zero.inflation = FALSE, one.inflation = FALSE,
prior.Sigma = "VC.unif", n.iter=2100, n.thin=10, n.burn=100)
xnew<- data.frame(x=BiRepeated[1:6,4])
pred.zoib(eg2,xnew)
}
Run the code above in your browser using DataLab