stockPie_fun: Pie chart of proportion of stocks relative to reference...

Description Usage Arguments Value Note Author(s) Examples

View source: R/plot_functions.R

Description

The stockPie_fun function returns pie charts of the proportion of stocks relative to reference points for fish categories in an ecoregion.

Usage

1
2
3
4
stockPie_fun(ecoregion, fisheries_guild = c("pelagic", "demersal",
  "crustacean", "elasmobranch", "benthic"), calculate_status = FALSE,
  data_caption = TRUE, file_name, active_year = 2016, save_plot = FALSE,
  return_plot = TRUE, return_data = FALSE, output_path = NULL)

Arguments

ecoregion

ecoregion name, e.g. Greater North Sea

fisheries_guild

fisheries guild to include in proportions

calculate_status

logical on whether to use raw SAG output to calculate stock status or to use the hard-coded values from stock summary table

data_caption

print the data source as a caption, boolean.

file_name

name for the output.

active_year

numeric of the stock database version (year). e.g., 2016

save_plot

logical to save plot.

return_plot

logical to return plot to current environment.

return_data

logical on returning a .csv of plotted data

output_path

path for output to live.

Value

A ggplot2 object or .png saved as file_name to output_path. When file_name is NULL, the file name is the ecoregion. When output_path is NULL, the file is saved to "~/".

Note

Stocks are linked to ecoregions and fish categories via the ICES Stock database. Reference points are as published in ICES Stock Assessment Graphs database. In some cases, status relative to reference points may vary from published ICES advice when reported F or SSB are very close to reference points (e.g., F = 0.201 > F<sub>MSY</sub> = 0.20). calculate_status = TRUE calculates stock status relative to published reference points. This will represent PA and SBL for ecoregions with proxy reference points. calculate_status = TRUE takes the raw icons from published advice. Note, before 2017 not all stocks status tables have been added to the SAG database and only few stocks had MSY proxy reference points.

Author(s)

Scott Large

Examples

1
2
3
4
## Not run: 
stockPie_fun("Greater North Sea Ecoregion", return_plot = TRUE)

## End(Not run)

slarge/fisheryO documentation built on May 30, 2019, 3:04 a.m.