# NOT RUN {
# load sample models:
data(rotif.mods)
# choose a particular model to play with:
mod <- rotif.mods$models[[1]]
predDensity(model = mod)
predDensity(model = mod, type = "histogram")
predDensity(model = mod, type = "density")
# you can also use 'predDensity' with vectors of
# observed and predicted values, instead of a model object:
presabs <- mod$y
prediction <- mod$fitted.values
predDensity(obs = presabs, pred = prediction)
predDensity(pred = prediction)
# }
Run the code above in your browser using DataLab