R/generics.R
, R/accessors.R
, R/constructors.R
FCB.Rd
The FCB slot in fwdControl specifies the relationships between the catches ('C') taken by each fishery ('F') from different biological units ('B').
The relationships between a fishery, its catch elements and the biological populations that catch is taken from, is part of the `fwdControl` class. When a single `FLBiol` and `FLFishery`, or just an `FLStock`, are projected forward, this structure is constructed on the fly. Even when multiple biols and fisheries are used, a guess is made based on name matching.
FCB(object, ...)
FCB(object, ...) <- value
# S4 method for fwdControl
FCB(object)
# S4 method for fwdControl,matrix
FCB(object) <- value
# S4 method for ANY
FCB(object, ...)
# S4 method for missing
FCB(object, ...)
# S4 method for FLBiols
FCB(object, fisheries)
# S4 method for FLFisheries
FCB(object, biols)
A list or vector containing a row for the matrix.
Further vectors to be merged into the matrix.
Input matrix
An `FLFisheries` object to extract fishery and catch names from.
An `FLBiols` object to match with `FLCatch` elements in `object`.
This slot is of class *matrix* and has thre columns, named 'F', 'C' and 'B', and as many rows as relationships between the FLBiol(s) and FLFishery(ies) objects the fwdControl refers to.
But when a more complex structure is employed, the `FCB` matrix can be given to the `fwdControl()` constructor method. Elements in this matrix can be names or numbers.
If `FLBiols` and `FLFisheries` objects are passed to `FCB`, a guess is made at constructing the matrix based on the names of the various list elements.
control <- fwdControl()
# Access FCB slot
FCB(control)
#> F C B
#> 1 NA NA NA
# Assign to existing fwdControl
FCB(control) <- FCB(c(f=1, c=1, b=2), c(f=1, c=2, b=2))
# 1 fishery with catches from 2 biols
FCB(c(f=1, c=1, b=2), c(f=1, c=2, b=2))
#> F C B
#> 1 1 1 2
#> 2 1 2 2
# 2 fisheries with caches from 3 biols
FCB(c(f=1, c=1, b=1), c(f=1, c=2, b=2),
c(f=2, c=1, b=2), c(f=2, c=2, b=2),
c(f=2, c=3, b=3))
#> F C B
#> 1 1 1 1
#> 2 1 2 2
#> 3 2 1 2
#> 4 2 2 2
#> 5 2 3 3