plot.dsm.var: Create plots of abundance uncertainty

Description Usage Arguments Value Details Author(s) See Also

View source: R/plot.dsm.var.R

Description

Note that the prediction data set must have x and y columns even if these were not used in the model.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
## S3 method for class 'dsm.var'
plot(
  x,
  poly = NULL,
  limits = NULL,
  breaks = NULL,
  legend.breaks = NULL,
  xlab = "x",
  ylab = "y",
  observations = TRUE,
  plot = TRUE,
  boxplot.coef = 1.5,
  x.name = "x",
  y.name = "y",
  gg.grad = NULL,
  ...
)

Arguments

x

a dsm.var object

poly

a list or data.frame with columns x and y, which gives the coordinates of a polygon to draw. It may also optionally have a column group, if there are many polygons.

limits

limits for the fill colours

breaks

breaks for the colour fill

legend.breaks

breaks as they should be displayed

xlab

label for the x axis

ylab

label for the y axis

observations

should observations be plotted?

plot

actually plot the map, or just return a ggplot2 object?

boxplot.coef

control trimming (as in summary.dsm.var), only has an effect if the bootstrap file was saved.

x.name

name of the variable to plot as the x axis.

y.name

name of the variable to plot as the y axis.

gg.grad

optional ggplot gradient object.

...

any other arguments

Value

a plot

Details

In order to get plotting to work with dsm.var.prop and dsm.var.gam, one must first format the data correctly since these functions are designed to compute very general summaries. One summary is calculated for each element of the list pred supplied to dsm.var.prop and dsm.var.gam.

For a plot of uncertainty over a prediction grid, pred (a data.frame), say, we can create the correct format by simply using pred.new <- split(pred,1:nrow(pred)).

Author(s)

David L. Miller

See Also

dsm.var.prop, dsm.var.gam, dsm.var.movblk


dsm documentation built on March 27, 2021, 9:07 a.m.