Get a data frame with options available in PacFIN and their descriptions. PacFIN documentation refers to these data frames as code_lists, thus the function name get_codelist helps explain what we are getting.

get_codelist(x = c("GEAR", "INPFC", "PORT"))

Arguments

x

A character value specifying which code_list you want. See the function call for the available lists or utils::methods("get_codelist") for a list of all of the available .S3methods.

Value

A data frame with the following potential columns, where the column names are always in all caps:

TYPE

integer value of 1 (gear code), 2 (gear group), or 3 (all)

PACFIN_GEAR_CODE

three letter grid or gear type code

GROUP

three letter gear grouping code

INPFC_AREA_TYPE_CODE

mapping of sub area to areas

INPFC

International North Pacific Fisheries Commission (INPFC) Area code used in PacFIN

TYPE

classification of tree structure, i.e., if it is a subarea

COUNCIL

the management council that the area falls within

PACFIN_PORT_CODE

character port code

AGENCY_CODE

agency code, e.g., "W" for Washington

AGENCY_PORT_CODE

numeric port code

SHORT

short description

DESCRIPTION

long, detailed description

Details

S3: This is an S3 class object, of which I am not very familiar with. Thus, feel free to provide comments on the code or submit an issue if you have ideas or corrections.

source: All PacFIN code lists are publicly available. As time progresses, I hope to have all lists available within R through code_lists. If you have time to add any of this functionality, feel free to submit a pull request and thank you in advance for collaborating.

Examples

availablegrids <- get_codelist("GEAR")
availableports <- get_codelist("PORT")
availableinpfc <- get_codelist("INPFC")