q_gap_biomass.Rd
six areas are available to query from bs = bering sea + northwest 1987-present (includes nw stations) - recommended bsslope = bering sea slope nbs = northern bering sea ai = aleutian islands goa = gulf of alaska old_bs = bering sea standard 1982-present (minus ~20 stations in nw) - not recommended
q_gap_biomass(
year = 2024,
species = 10110,
area = "bs",
type = "region",
db,
print_sql = FALSE,
save = TRUE
)
max year to retrieve data from, and default folder location
5 digit afsc species code(s) e.g., 79210 or c(79210, 90210)
options are bs (the bs+nw), bsslope, nbs, ai, goa, old_bs (was called "standard") - can only call a single area
the goa and ai have: region, regulatory_area, stat_area, stratum, inpfc, inpfc_depth, depth, (ai only: reg_area_depth); the bs has: region, subarea, stratum, depth; the bsslope has: region, subarea, stratum; the nbs hasregion, stratum - can only use a single type (default: "region")
the database to query (akfin)
outputs the sql query instead of calling the data (default: false)
save the file in designated folder, if FALSE outputs to global environment
saves bts biomass data as data/raw/(area)_(type)_bts_biomass_data.csv or outputs to the global environment, also saves a copy of the SQL code used for the query and stores it in the data/sql folder.
if (FALSE) {
db <- afscdata::connect()
q_bts_biomass(year=2024, species=10110, area="bs", type="region", db=db)
}