plot_kobe: Make Kobe contour plots by management procedure for B/BMSY by...

View source: R/figures-kobe.R

plot_kobeR Documentation

Make Kobe contour plots by management procedure for B/BMSY by F/FMSY

Description

Make Kobe contour plots by management procedure for B/BMSY by F/FMSY

Usage

plot_kobe(
  object,
  yend = max(object@proyears),
  dontshow_mp = NULL,
  show_ref_pt_lines = TRUE,
  alpha = c(0.25, 0.5, 0.75),
  n = 200,
  xlim = c(0, 3.5),
  ylim = c(0, 3.5),
  x_ref_lines = c(0.4, 0.8),
  y_ref_lines = 1,
  show_contours = TRUE,
  return_data = FALSE,
  french = isTRUE(getOption("french"))
)

plot_kobe_grid(object_list, french = isTRUE(getOption("french")), ...)

Arguments

object

An MSE object as returned by MSEtool::runMSE().

yend

The end year

dontshow_mp

A vector of MPs to leave out of the plot.

show_ref_pt_lines

Show the reference point lines at the values in *_ref_lines arguments

alpha

A vector of levels between 0 and 1 for the contour lines.

n

As defined in MASS::kde2d().

xlim

The ggplot2::xlim() values for x-axis limits.

ylim

The ggplot2::ylim() values for y-axis limits.

x_ref_lines

A vector of vertical lines to draw as reference point lines.

y_ref_lines

A vector of horizontal lines to draw as reference point lines.

show_contours

Logical: show contour lines?

return_data

Logical: return the data instead of the plot?

french

French?

object_list

A list of MSEtool MSE objects representing different scenarios. The list should be named with the scenario names.

...

Other arguments to pass to plot_kobe().

Value

A ggplot object

Examples

plot_kobe(mse_example)
x <- list()
x[[1]] <- mse_example
x[[2]] <- mse_example
names(x) <- c("Scenario 1", "Scenario 2")
plot_kobe_grid(x)

pbs-assess/ggmse documentation built on Nov. 21, 2023, 8:06 p.m.