Description Generic function Methods Author(s) See Also Examples
metier
returns a linkS4class{FLMetier}
object from a
linkS4class{FLFleet}
. They can also be accessed directly by using the
'[' and '[[' methods, see example below.
metier(object,metier)
Returns the FLMetier with the given name.
The FLR Team
FLMetier, FLFleet, FLCatch, Extract-FLCore
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 | data(bt4)
names(metiers(bt4))
# calling the FLMetier with the metier method
met <- metier(bt4,metier='TBB')
met <- metier(bt4,'TBB')
# calling the lower levels with the '[' and the '[[' operators
fl1 <- bt4['TBB'] # returns a fleet with only the 'TBB' metier
met1 <- bt4[['TBB']] # returns the metier
fl2 <- bt4['TBB','ple'] # returns a fleet with only the 'ple' catch for 'TBB' metier
fl3 <- bt4[,'ple'] # returns a fleet with only the 'ple' catch
# possible combinations of the two include:
ca1 <- bt4[['TBB']][['ple']] # returns the 'ple' FLCatch from metier 'TBB'
met2 <- bt4[['TBB']]['ple'] # returns the 'TBB' metier with only the 'ple' catches
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.