View source: R/PacFIN.Catch.Extraction.R
PacFIN.Catch.Extraction | R Documentation |
Extract commercial fisheries catch data from fish tickets supplied by fish processing plants when the fish were delivered. This data is archived in the Comprehensive_FT table contained within the PacFIN (https://pacfin.psmfc.org/) database.
PacFIN.Catch.Extraction(
PACFIN_SPECIES_CODE = "('CNRY','CNR1')",
PacFIN_Common_Name = NULL,
UID = PacFIN.Login,
PWD = PacFIN.PW,
minYr = 1900,
maxYr = 2100,
verbose = TRUE,
addColsWithLegacyNames = TRUE
)
PACFIN_SPECIES_CODE |
A character vector of PacFIN species code or codes. For species with a nominal category use, e.g.: PACFIN_SPECIES_CODE = "('PTRL', 'PTR1')". Otherwise, for major species that are always separated out in the catch use: e.g.: PACFIN_SPECIES_CODE = "'SABL'". |
PacFIN_Common_Name |
A character vector of PacFIN species common name used only for checking for a nominal species ID. The function will stop after the species codes are printed. |
UID |
A character vector of for the PacFIN login. The default is 'PacFIN.Login', which can be set prior to running this function. |
PWD |
A character vector of for the PacFIN password. The default is 'PacFIN.PW', which can be set prior to running this function. |
minYr |
The minimum year for which data is to be extracted. |
maxYr |
The maximum year for which data is to be extracted. |
verbose |
A logical object. When TRUE, verbose output will be printed. When FALSE, only differences and ratios of INPFC and PSMFC areas will be printed. The default is TRUE. |
addColsWithLegacyNames |
When TRUE, historically used columns will be copied and given legacy names, mostly from the 'vdrfd' PacFIN table. The default is currently TRUE. |
An R list with the following data frames: 'CompFT' contains the comprehensive Fish Ticket information; PacFIN.INPFC.Summary.Catch' is catch summed over INPFC areas by year, agency, and port; 'PacFIN.PSMFC.Summary.Catch' is catch summed over PSMFC areas by year, agency, and port; Catch.mt.by.Agency.Year.Fleet is catch summarized by agency, year, and fleet, 'Tribal.Catch.mt.by.Year.Gear' is tribal catch data summarized by year and gear type.
John R. Wallace
PacFIN.Login <- "jonesj"
PacFIN.PW <- "????????"
PacFIN.PTRL.Catch <- PacFIN.Catch.Extraction("('PTRL', 'PTR1')")
PacFIN.SABL.Catch <- PacFIN.Catch.Extraction("'SABL'")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.