Learn R Programming

ss3sim (version 0.9.5)

profile_fmsy: Determine Fmsy for a given operating model

Description

Runs an operating model over a range of fishing mortality levels to determine the profile of F values from which Fmsy can be determined.

Usage

profile_fmsy(om_in, results_out, start = 0, end = 1.5, by_val = 0.01,
  ss_mode = c("safe", "optimized"))

Arguments

om_in

A directory for an ss3sim operating model.

results_out

A directory to place the results

start

Lower fishing mortality level

end

Upper fishing mortality level

by_val

Interval in which you wish to increment the fishing mortality level

ss_mode

SS3 binary option. One of "safe" for the safe version of SS3 or "optimized" for the optimized version of SS3. The relevant binary needs to be in your system's path. See the vignette vignette("ss3sim-vignette", package = "ss3sim") for details and links to the binary files. Defaults to safe mode.

Value

Creates a plot and a table with catches and F values (see the results_out folder). Also invisibly returns the Fmsy table as a data frame.

Details

This function extracts the number of years from the model dat file and then runs at a constant level of fishing for each year, extracting the catch in the last year. This assumes the length of the model is long enough to reach an equilibrium catch. The user is responsible for ensuring this fact.

Examples

Run this code
# NOT RUN {
d <- system.file("extdata", package = "ss3sim")
omfolder <- paste0(d, "/models/cod-om")


fmsy.val <- profile_fmsy(om_in = omfolder, results_out = "fmsy",
  start = 0.1, end = 0.2, by_val = 0.05)
# }

Run the code above in your browser using DataLab