plot.joint {JointModeling} | R Documentation |
Graphicals representation to help in model checking.
## S3 method for class 'joint': plot(x, comp = "mean", var = NULL, res = 'standard', which = 1:5, ask = nb.fig < length(which) && dev.interactive(), smooth = TRUE, ...) obs.vs.model(x.joint, plot.disp = FALSE, ...) rstand.vs.linpred(x, smooth = TRUE, ...) res.vs.explvar(x, var, res = 'standard', smooth = TRUE, ...) absres.vs.fitted(x, res = 'standard', smooth = TRUE, ...) adjvar.vs.linpred(x, smooth = TRUE, ...) qqglm(x, ...)
x,x.joint |
A fitted GLM/GAM object or a fitted joint model. |
comp |
The component for the joint model. Must be one of
"mean" or "disp" . |
var |
Character. The name of the explanatory variable selected. |
res |
Character. Should be standard, student of brut. The residual type considered. |
which |
Numeric vector. Which plot must be produced. |
ask |
Logical. If TRUE , user is asked before a new plot is
produced. |
smooth |
Logical. If TRUE - the default, a smoothing curve
is plotted thanks to the lowess fucntion. |
... |
Optional parameters to be passed to plot ,
abline and qqnorm functions. |
plot.disp |
Logical. Should the +/- standard deviation error bar
be plottted around the point selected by the identify
function. |
The function plot.joint
is a special function
to compute all the checking plots. Checking plots implemented are :
Several conclusions can be established thanks to these plots. One can refer to McCullagh and Nelder, 1987 for interpretation.
Return a (several) graphic window(s).
Mathieu Ribatet and Bertrand Iooss
McCullagh P. and Nelder J. A. (1987). Generalized Linear Models Second Edition. London: Chapman and Hall. ISBN 0-412-31760-5.
X <- rnorm(500, 5) mu <- 2*X + 1 sigma2 <- exp(-X) Y <- rnorm(500, mu, sqrt(sigma2)) data.frm <- data.frame(Y=Y, X=X) ajust <- fitjoint("glm", 'Y~X', 'd~X', data = data.frm) layout(matrix(c(1,1,2,2,3,3,4,4,0,5,5,0),3,byrow=TRUE)) plot(ajust, var = 'X')