show.Dsurf | R Documentation |
Plots density surface estimated by a model fitted with the function fit.ascr.
show.Dsurf( fit, session = 1, newdata = NULL, show.cv = FALSE, unsuitable = NULL, xlim = NULL, ylim = NULL, zlim = NULL, scale = 1, plot.contours = TRUE, add = FALSE )
fit |
A fitted model from fit.ascr. |
session |
The session with the detector array and invidual(s)
to be plotted. Ignored if the |
newdata |
A data frame including new mask points and covariate
values, from which to estimate and plot density estimates
for. This allows, for example, estimates to be provided for new
regions not included in the mask used to fit the model. Two
columns, named |
show.cv |
Logical. If true, the CV of the density estimate is
plotted rather than the estimate itself. At present, this will
only work if |
unsuitable |
A data frame with two columns, named |
xlim |
A numeric vector of length 2, giving the x coordinate range. |
ylim |
A numeric vector of length 2, giving the y coordinate range. |
zlim |
A numberic vector of length 2, giving the range of density contours. |
scale |
By default, density is in animals per hectare. The
plotted values are multiplied by this argument, allowing for
user-specified units. For example, setting |
plot.contours |
Logical, if |
add |
Logical, if |
simple.capt <- example.data$capt[1] cov.df <- data.frame(x = example.data$mask[, 1]/1000, y = example.data$mask[, 2]/1000) fit <- fit.ascr(capt = simple.capt, traps = example.data$traps, mask = example.data$mask, fix = list(g0 = 1), ihd.opts = list(model = ~ x + y, covariates = cov.df)) show.Dsurf(fit)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.