lurking.mppm | R Documentation |
Generate a lurking variable plot of spatial point process residuals against a covariate, for a model fitted to several point patterns.
## S3 method for class 'mppm' lurking(object, covariate, type="eem", ..., separate = FALSE, plot.it = TRUE, covname, oldstyle = FALSE, nx = 512, main="")
object |
The fitted model. An object of class |
covariate |
The covariate to be used on the horizontal axis.
Either an |
type |
String indicating the type of residuals or weights to be computed.
Choices include |
... |
Additional arguments passed to |
separate |
Logical value indicating whether to compute a separate lurking
variable plot for each of the original point patterns.
If |
plot.it |
Logical value indicating whether
plots should be shown. If |
covname |
A string name for the covariate, to be used in axis labels of plots. |
oldstyle |
Logical flag indicating whether error bounds should be plotted
using the approximation given in the original paper
( |
nx |
Integer. Number of covariate values to be used in the plot. |
main |
Character string giving a main title for the plot. |
This function generates a ‘lurking variable’ plot for a
point process model fitted to several point patterns.
Residuals from the model represented by object
are plotted against the covariate specified by covariate
.
This plot can be used to reveal departures from the fitted model.
The function lurking
is generic. This is the method
for the class mppm
.
The argument object
must be a fitted point process model
object of class "mppm"
) produced by the
model-fitting algorithm mppm
.
If separate=FALSE
(the default),
the return value is an object
belonging to the class "lurk"
, for which there
are methods for plot
and print
.
See lurking
for details of the format.
If separate=TRUE
, the result is a list of such objects,
and also belongs to the class anylist
so that it can be
printed and plotted.
, with thanks to Nicholas Read.
lurking.ppm
fit <- mppm(Points ~ Image + Group, demohyper) lurking(fit, expression(Image), type="P") lurking(fit, expression(Image), type="P", separate=TRUE)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.