calc_numbers_at_length: Calculates the numbers of fish at length

View source: R/calc_numbers_at_length.r

calc_numbers_at_lengthR Documentation

Calculates the numbers of fish at length

Description

Given the landings (expanded by length), and the length-weight relationship, the number of fish at a given length is calculated.

Usage

calc_numbers_at_length(expLandings, lengthWeightParams)

Arguments

expLandings

Tibble. Expanded langings by length (from expand_landings_to_lengths)

lengthWeightParams

List. alpha = intercept, betas = slope(s), var = residual variance used to formulate the mean (?see Notes section below)

Details

THIS NEEDS TO BE GENERALIZED.

Value

A Tibble of expanded landings to represent weight of landings by length

YEAR

Year of landings

NEGEAR

3 digit gear code as defined in cfdbs.gear

TIME

Quarter/Half year of landings (The presence of this field depends on whether it was present in the landingsData

MARKET_CODE

Market code assigned to landed fish (The presence of this field depends on whether it was present in the landingsData

LENGTH

Length of sampled fish

NUMLEN

number of sampled for fish stated LENGTH

weight

expanded weight (mt) of all fish of given LENGTH in YEAR, NEGEAR etc..

Notes

The length weight relationship (see fit_length_weight) is fit assuming log normal errors (normal on the log scale). Therefore when exponentiating a correction for the estimate is required:

E(W) = \alpha L^\beta exp(\sigma^2 / 2)


NOAA-EDAB/neusCatch documentation built on Oct. 17, 2023, 7:07 a.m.