message("Starting modelComparisons.EstimatedCharacteristics.Fisheries.Rmd")
    ##input model list
    Models<-params$Models;
    doc_type<-params$doc_type;
    plot1stObs<-params$CharacteristicsForFisheries$plot1stObs;
    message(paste0("verbose = ",params$CharacteristicsForFisheries$verbose,"\n"))

    ##set knitr options for subsequent chunks
    knitr::opts_chunk$set(echo=FALSE, error=FALSE, message=FALSE, warning=FALSE, concordance=TRUE, fig.width=6.5, fig.height=7.0, dpi=300)

    ##set caption numbering
    if (!exists("fig")){
      fig<-1;#figures
      tbl<-0;#tables
    }

    cases<-names(Models);
    nCases<-length(cases);

Estimated fishery characteristics

Model-estimated fishery characteristics such as catchability and selectivity and retention functions are presented in this section.

\clearpage

Fishery catchability

  message("Starting EFCs01.Catchability")
  plts<-rCompTCMs::compareResults.Fisheries.Catchability(Models,
                                                         fleets=params$CharacteristicsForFisheries$fleets,
                                                         dodge=0,
                                                         showPlot=FALSE,
                                                         verbose=params$CharacteristicsForFisheries$verbose)
  if ((!is.null(plts))&&(length(plts)>0)){
      captions<-wtsUtilities::getCaptionsFromGGPlotList(plts);
      for (plt in plts) {print(plt); cat("\n\n"); fig<-fig+1;}
      rm(plt,plts);
  }

\FloatBarrier

\clearpage

Total selectivity functions

  message("Starting EFCs02.SelFcns")
  plts<-rCompTCMs::compareResults.Fisheries.SelFcns(Models,
                                                    cast="y+x",
                                                    facet_grid="y~x",
                                                    mxy=5,
                                                    fleets=params$CharacteristicsForFisheries$fleets,
                                                    years=params$CharacteristicsForFisheries$selyears,
                                                    dodge=0,
                                                    showPlot=FALSE,
                                                    verbose=params$CharacteristicsForFisheries$verbose);
  if ((!is.null(plts))&&(length(plts)>0)){
      captions<-vector(mode="character",length=0);
      for (fplts in plts) {
        captions<-c(captions,wtsUtilities::getCaptionsFromGGPlotList(fplts));
        for (plt in fplts) {
          print(plt); cat("\n\n"); fig<-fig+1;
        }
      }
      rm(plt,fplts,plts);
  }

\FloatBarrier

\clearpage

Retention functions

  message("Starting EFCs03.RetFcns")
  plts<-rCompTCMs::compareResults.Fisheries.RetFcns(Models,
                                                    cast="y+x",
                                                    facet_grid="y~x",
                                                    mxy=5,
                                                    fleets=params$CharacteristicsForFisheries$fleets,
                                                    years=params$CharacteristicsForFisheries$retyears,
                                                    dodge=0,
                                                    showPlot=FALSE,
                                                    verbose=params$CharacteristicsForFisheries$verbose);
  if ((!is.null(plts))&&(length(plts)>0)){
      captions<-vector(mode="character",length=0);
      for (fplts in plts) {
        captions<-c(captions,wtsUtilities::getCaptionsFromGGPlotList(fplts));
        for (plt in fplts) {
          print(plt); cat("\n\n"); fig<-fig+1;
        }
      }
      rm(plt,fplts,plts);
  }


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