ArraySpeciesBySize objectsSee plot() for an overview of the mizer plotting system and the
arguments shared by all of its methods.
# S3 method for ArraySpeciesBySize
plot(
x,
species = NULL,
all.sizes = FALSE,
highlight = NULL,
return_data = FALSE,
log_x = TRUE,
log_y = FALSE,
log = NULL,
wlim = c(NA, NA),
llim = c(NA, NA),
ylim = c(NA, NA),
size_axis = c("w", "l"),
per_log_size = NULL,
total = FALSE,
background = TRUE,
y_ticks = 6,
...
)A ggplot2 object, unless return_data = TRUE, in which case a
data frame is returned.
An ArraySpeciesBySize object.
Character vector of species to include. NULL
(default) means all species.
If FALSE (default), values outside a species' size
range (w_min to w_max) are removed.
Name or vector of names of the species to be highlighted.
If TRUE, return the data frame instead of the
plot.
If TRUE, use a log10 x-axis. Default is TRUE.
If TRUE, use a log10 y-axis. Default is FALSE.
Character string specifying which axes should use log10
scales, in the same form as the base plot() argument. For example,
"x", "y", "xy" or "". If supplied, this overrides log_x and
log_y.
A numeric vector of length two providing lower and upper
limits for the weight (x) axis. Use NA to refer to the existing
minimum or maximum.
A numeric vector of length two providing lower and upper
limits for the length (x) axis when size_axis = "l". Use NA to
refer to the existing minimum or maximum.
A numeric vector of length two providing lower and upper
limits for the value (y) axis. Use NA to refer to the existing
minimum or maximum.
Whether to plot size as weight ("w", default) or
length ("l"), using the allometric weight-length relationship.
For an array that holds a density, whether to plot it per
logarithmic size (TRUE) rather than per size (FALSE). The default,
NULL, plots the density as it stands. Unlike size_axis this needs no
weight-length relationship, so it is available for the resource classes
too. An error for an array that does not hold a density.
A boolean value that determines whether the total is plotted
as well. The total is the total of everything the array holds, every
species and every size, whatever is drawn. Default is FALSE.
A boolean value that determines whether background
species are included. Ignored if the model does not contain background
species. Default is TRUE.
The approximate number of ticks desired on the y axis.
Unused.
# \donttest{
plot(getEncounter(NS_params))
plot(getFeedingLevel(NS_params), species = c("Cod", "Herring"))
plot(getPredMort(NS_params), species = c("Cod", "Herring"),
size_axis = "l")
# }
Run the code above in your browser using DataLab