Calculate log likelihood over a grid of values of two beta parameters from a fitted openCR model and optionally make an approximate contour plot of the log likelihood surface.
This is a method for the generic function LLsurface
defined in secr.
# S3 method for openCR
LLsurface(object, betapar = c("phi", "sigma"), xval = NULL, yval = NULL,
centre = NULL, realscale = TRUE, plot = TRUE, plotfitted = TRUE, ncores = NULL, ...)
Invisibly returns a matrix of the log likelihood evaluated at each grid point
openCR
object output from openCR.fit
character vector giving the names of two beta parameters
vector of numeric values for x-dimension of grid
vector of numeric values for y-dimension of grid
vector of central values for all beta parameters
logical. If TRUE input and output of x and y is on the untransformed (inverse-link) scale.
logical. If TRUE a contour plot is produced
logical. If TRUE the MLE from object
is shown on the plot (+)
integer number of cores available for parallel processing
other arguments passed to contour
centre
is set by default to the fitted values of the beta
parameters in object
. This has the effect of holding parameters
other than those in betapar
at their fitted values.
If xval
or yval
is not provided then 11 values are set at
equal spacing between 0.8 and 1.2 times the values in centre
(on
the `real' scale if realscale
= TRUE and on the `beta' scale
otherwise).
Contour plots may be customized by passing graphical parameters through the ... argument.
The value of ncores
is passed to openCR.fit
.
LLsurface.secr