compareFits.BiomassData: Compare fits to biomass time series by fleet among several...

View source: R/compareFits.BiomassData.R

compareFits.BiomassDataR Documentation

Compare fits to biomass time series by fleet among several model runs

Description

Function to compare fits to biomass time series by fleet among several model runs.

Usage

compareFits.BiomassData(
  objs = NULL,
  fleets = "all",
  fleet.type = c("survey", "fishery"),
  catch.type = c("index", "retained", "discard", "total"),
  ci = 0.8,
  fishery.pdfType = c("norm2", "normal", "lognormal"),
  numRecent = 15,
  plot1stObs = TRUE,
  scales = "free_y",
  position = position_dodge(0.3),
  pdf = NULL,
  showPlot = FALSE,
  verbose = FALSE
)

Arguments

objs
  • object that can be converted into a list of tcsam2013.resLst and/or tcsam02.resLst objects, OR a melted dataframe

fleets
  • names of fleets to include (or "all")

fleet.type
  • fleet type ('fishery' or 'survey')

catch.type
  • catch type ('index','retained', or 'total')

ci
  • confidence interval for plots

fishery.pdfType
  • choice for fishery CIs ("norm2","normal","lognormal")

numRecent
  • number of recent years to include in "recent years" plots

plot1stObs
  • flag (T/F) to plot observations only from the first model

scales
  • ggplot2 scales option for facet_grid

position
  • indicates ggplot2 position_ to use ('dodge','jitter','identity',)

pdf
  • name for output pdf file

showPlot
  • flag (T/F) to show plot

verbose
  • flag (T/F) to print diagnostic information

Details

If objs is a list, then extractMDFR.Fits.BiomassData() is used to extract a melted dataframe in canonical format with the biomass observations and predictions to be plotted. objs can also be a melted dataframe from a previous call to extractMDFR.Fits.BiomassData(). Also uses wtsUtilities::printGGList().

Value

Non-nested list of ggplot2 objects, with captions as names, or NULL.


wStockhausen/rCompTCMs documentation built on Sept. 12, 2023, 3:13 p.m.