# Non-formula fit
mod <- iprior(y = stack.loss,
air = stack.x[,1],
water = stack.x[,2],
acid = stack.x[,3])
predict(mod, newdata = list(air = 58, water = 20, acid = 87))
# Formula fit
mod.orange <- iprior(circumference ~ . ^ 2, data = Orange[-1, ])
predict(mod.orange, Orange[1, ])
Run the code above in your browser using DataLab