Run all the analysis together

run(
  species_name,
  catch_data,
  em_catch_data,
  biological_data,
  format_gemm_data,
  data_grouping,
  length_bins = seq(10, 60, 2),
  age_bins = 1:30,
  dir = NULL,
  n_boot = 10000
)

Arguments

species_name

Species name to process discard biological data for. The casing needs to match WCGOP biological species column that capitalizes the first letter of each name (e.g., Canary Rockfish, Sablefish).

catch_data

A data frame of WCGOP catch data that includes all species. This data frame will be used to check confidentiality.

em_catch_data

A data frame of WCGOP EM catch data that includes all species.

biological_data

A data frame of WCGOP biological data that includes all species. The full biological data frame is filtered down to selected species and to include only discard data (catch_disposition == "D").

format_gemm_data

Data frame of GEMM data created by format_gemm() or format_gemm_alt()

length_bins

Vector of integers to bin length data by to create discard composition data. Values above or below the minimum or maximum values in the vector are grouped into the first size or plus group size, respectively. For example, creating length compositions that uses a vector bin of seq(10, 50, 2) would create 2 cm bins where fish length between [0, 11.99) would be included in the 10 cm bin, fish of length [12, 13.99) would be included in the 12 cm bin, and all fish [50- Inf) would be included in the 50 cm plus bin.

age_bins

Vector of integers to bin age data by to create discard composition data. Values above or below the minimum or maximum values in the vector are grouped into the first age or plus group age, respectively. For example, creating age compositions that uses a vector bin of seq(1, 20, 1) would create 1 year age bins where fish age between [0, 1) would be included in the 1 age bin and all fish [20- Inf) would be included in the 20 age plus bin.

dir

Directory where output will be saved. The directory where the file should be saved. If dir = NULL no output will be saved.

Author

Chantel Wetzel