The current version of the DLMtool package is available for download from CRAN.
LBSPR MP due to issues with compiling the C+
codeLBSPR when calendar years are provided in
Data@YearCV_Ind in
IratioLtargetE MP where it was incorrectly
averaging across simulations (thanks to Ernesto Carrella
for spotting this)LBSPR MP updated to handle missing CAL dataLBSPR is now recursiveV6.0.0 is a major update to the DLMtool package. It is
not backwards compatible with previous versions of DLMtool
or MSEtool.
DLMtool package is now limited to the
collection of the data-limited management procedures.MSEtool (v3+).MSEtool v3+ is a dependency for DLMtool
v6+, and all operating model simulation and projection functions are
available after installing and loading DLMtool.cpars$DR_y - matrix nsim rows and nyears+proyears
columnsRec@DR)OM@cpars$qs). Doesn’t optimize for depletion and updates
OM@D.Data@AddInd) can now
be specified using Data@AddIunits (numeric vector length
n.ind 1=biomass (default) 0=numbers).Data@AddIndType (numeric vector length n.ind
1=total stock (default), 2=spawning stock, 3=vulnerable stock).Misc$Removals wasn’t being returned in
parallel mode.XL2OM for latest version of R (behavior
of base::data.matrix changed)OM@cpars$control$Sample_Area; e.g.,
OM@cpars$control$Sample_Area$Catch The following names are
accepted:
Catch (includes average catch);BInd total biomass indexSBInd spawning biomass indexVInd vulnerable biomass indexRecInd recruitment indexCAA - catch-at-ageCAL - catch-at-length (also applies to mean length,
length-at-first capture, etc) Each must be an array with dimensions
c(nsim, nyears+proyears, nareas).DT package broke
PMObj and PMLimit tablesOM@cparsLBSPR_MLL MPvalidcpars now returns a HTML data table with
information on parameters that can be passed in
OM@cparsData@VInd and
Data@SpInd for relative vulnerable and spawning abundance
respectively. Also add CV slots for each. Note that these use the same
observation error and betas as Data@Ind (total abundance)
and all built-in MPs use Data@Ind.Sub function now subsets Data in MSE object by MP.Converge now returns a summary table of convergence
diagnostics (thanks to Sarah Valencia)MSE@Misc$RemovalsData@AddInd can now be specified with
cpars$AddIUnits: numeric vector of length
n.ind with 1 specifying biomass (default) and 0 abundance
by numbers.SuggestsForceCor, use
LH2OM insteadcpars$Mat_age) are greater than 0.5. Assume A50 is 1 in
this case.cpars$DataCAL_bins or binWidth in
cparsData@AddIndData object has been updated, main new features are
the addition of an Effort slot (Data@Effort and
Data@CV_Effort) and all CV by year for all time-series
information.Data@RInd slot has been removed and replaced with
Data@AddIndCplot (thanks Sarah Valencia for picking
this up)runMSE(Hist=TRUE) where under some
conditions the Hist object could not be stitched back
together.AAVE)
performance objective methodPMObj functionCurCDom function (and removed old DOM
function)SS2OM). To use a plus-group, use
OM@cpars$plusgroup = 1OM@cpars$binWidthTradePlotcpars$mov when nareas>2runMSE function is now more robust. MPs that fail
(i.e. crash R) are now skipped without stopping the entire MSE. A
warning message alerts users which MPs have been dropped from the
analysis.runMSE(Hist=TRUE) returns a new S4 object of class
‘Hist’. This change means that information from historical simulations
is now accessed using @ instead of $. For
example: Hist <- runMSE(Hist=TRUE)
TS <- Hist@TSdata # time-series data
Data <- Hist@Data # Data object from end of historical periodrunMSE(Hist=TRUE) now works with parallel
processingcheatsheetsOM@cpars$mov.Uses function has been added to return MPs that use a
particular data slot. For example: Uses('AvC)OM@cpars$initD.PMLimit and PMObj have been
added to generate interacive HTML tables showing the performance of MPs
(using objects of class PM)Labels has been added to the
TradePlot function and related functions
(Tplot etc). This allows users to replace the default MP
name with something more user-friendly. For example:
TradePlot(MSE, Labels=list(AvC="Average Catch")). An
argument cols has also been added so users have full
control on the colors of the points and labels. The MP labels can be
removed completely by setting the lab.size argument to
NULLStock@Mgrad, Stock@Linfgrad) have been
removed. Time-varying parameters should now be specified with
OM@cpars.AnnualMSY argument is now deprecated. MSY reference
points are now always calculated in every time-step.runMSErobust function has been now removed from
package (it was broken in the previous version).Data objects with larger
number of length binscurE75 which was ratcheting down
effortTuring functionTuring functionsummary(Data)cheatsheets()Growth2OM)LW2OM).plotMPA to include relative size of areasMSE@OM has been updated to only include historical
conditions.Converge in 5.2.1XL2Data to read files from other than
working directorysummary(Data)PM functions when
MSE@nMPs == 1runMSE. OM@interval can now be a vector of
length nMPs, to specify different management intervals for
different MPs. For example, with OM@interval=c(1,5) and
runMSE(OM, MPs=c('AvC', 'BK')),AvCis applied every year andBKis applied every 5 years.OM@interval`
is recycled if not the same length as number of MPs.makeMeanMP has been added to generate a MP that
averages output from a list of other MPs.Turing has been added to compare simulated data from an
OM to the real data in the fishery Data object.LH2OM and predictLH have been added to
predict correlated life-history parameters from FishBase using FishLife
model.Converge
functionReplace function has been updated to replace directly
from individual Stock, Fleet, Obs, and Imp objects instead of from only
OM objectssummary(Data) function have been
improvedmakePerf has been replaced with tinyErr
function with options to remove process error, observation error, and
gradientsPM (Performance Metric) methods have been updated and
described in the user guideTrade_Plot,
Tplot, Tplot2, and Tplot3Fease has been simplified and updated. Fease object has
now been removedplot and examples in the
online documentationOM@cpars) have been updated and now
have better documentationuserguide() has been updated and
additional chapters added on new featuresData object:
Common_Name, Species, Region, and
for data-rich MPs in MSEtool: sigmaR (recruitment
error)setup() if
runsMSE(parallel=TRUE) and cluster hasn’t been
initializedrunsMSE(parallel=TRUE)SPmodMixed MPs: it is now possible to design MPs that combine Output and Input controls. Previously, MPs in DLMtool where either class ‘Input’ or class ‘Output’. This has changed, and all MPs are now class ‘MP’ and return a standard recommendation object (‘Rec’) that allows specification of any combination of catch limit, effort limit, spatial closure, and size-at-selection and/or size-at-retention regulations.
MP types: For convenience, MPs can be categorised into 4 types:
‘Output’ (only catch limits), ‘Input’ (only spatial, effort, and/or size
regulations), ‘Mixed’ (some combination of Output and Input
regulations), and ‘Reference’ (MPs such as FMSYref or NFref which are
designed to be used a references and not for actual applications). The
function MPtype can be used to determine an MP’s type, e.g
MPtype('AvC').
Increased flexibility of selectivity, retention, and discard mortality controls: MPs can now modify both selectivity and retention curves, and also modify the level of discard mortality.
Historical MPAs: A new slot MPA has been added to
the Fleet object. This allows users to specify the
historical year and the fraction of an area that was closed. See
?plotMPA for an example.
Improvements to MSY reference point calculations: MSY reference points are now calculate for every year. This accounts for changes in productivity (e.g., increases in growth) that affect reference points such as BMSY and FMSY.
Increased number of areas: By default DLMtool is a 2-area model. The code has now been updated to include more areas if required.
Movement by age: It is now possible to specify movement by age, such as ontogenetic migration offshore
Parallel processing: runMSE has been optimized for
parallel processing. By default, parallel processing is not used if
nsim<=48. We suggest testing your OM with a low number
of simulations (e.g nsim=48) and then increasing the number
of simulations and using parallel processing:
runMSE(OM, MPs, parallel=TRUE). Update messages are not
displayed in parallel mode.
Taxonomic information: New slots have been added to the
Stock object to record common name and taxonomic
details.
The Converge function has been updated with a
improved of convergence diagnostics.
A new performance metric (PM) class has been added.
This allows users to develop a custom set of performance metrics for
their management system. A series of example PM objects
have been created (see avail('PM')). Over time the summary
and plotting functions will be updated to take a set of PM
objects. See Tplot3 for an example.
Many improvements to functions (e.g MPs) to improve robustness and avoid model crashes due to stochastic sampling of parameters.
All code in DLMtool is now tested using the testthat
package to ensure that the functions work as expected. Please continue
to file bug reports at:
https://github.com/DLMtool/DLMtool/issues
The User Manual has been completely revised and updated. Use
userguide() to access. Please submit any typo corrections
or suggestions for improvement at
https://github.com/DLMtool/DLMtool_UserGuide/issues. Pull requests are
welcome.
We are developing an online library of DLMtool OMs (http://www.datalimitedtoolkit.org/fishery_library) which has the OM Report, OM Excel file, and OM R data object for each DLMtool OM. A standardized MSE report is in development. The OM library will be expanded as new OMs are developed. Please contact us if you have developed OMs and are able to make them publicly available.
A DLMtool user forum is in development and will be launched soon. The idea of the forum is to provide a platform for DLMtool users to ask questions and share experience with each other and the DLMtool team.
The following slots have been added to the OM object:
OM@intervalOM@pstarOM@maxFOM@repsThis was done so that an OM object is completely self-contained and includes all information used in the MSE.
Objects names have been shortened and modified for consistency:
Implementation error and a dedicated implementation error object called ‘Imp’, (like Stock, Fleet and Obs) that can account for variability and overages/underages in both effort, catch and size limit advice (discarding rate and post release mortality rate are coming soon)
At least 10 new example operating models from real DLMtool applications in the US and Canada
Stochastic SRA operating model functions (i.e. build a full operating model accounting for correlations in parameters using historical catch trends and some composition data)
Full plots of operating model conditions
Stock-synthesis assessment to DLM function for specifying operating models (currently MLE only but adding MCMC and hessian options)
iSCAM assessment to DLM support for specifying operating models (MPD only but adding MCMC and hessian options soon)
Tracking of historical versus current simulated age composition in catches and population over simulations
New function ‘Replace’ for copying parts of an operating model to another operating model (e.g. Robin Hood approach,where you may want to borrow say, the fleet characteristics from another operating model)
Estimation of a new reference point ‘Blow’ for calculation of conservation-related performance metrics (Blow is the spawning biomass where it takes HZN number of mean generation times to reach Bfrac fraction of SSBMSY given zero catches, where the user can specify HZN and Bfrac).
Canadian DFO performance plots (DFO_hist, DFO_proj, DFO_plot2)
Biomass recovery relative to Blow plots (COSEWIC_plot)
A dedicated custom parameters slot in the operating model object. This is a list where the user can place custom parameters samples (from any distribution / correlation structure you wish) that are named as they appear in the operating model.
DLMdat have now been added as
separate data objects. This means that it is no longer necessary to
unpack data objects at the beginning of an R session.setup()runMSE and runMSErobust functions have a
new logical argument Hist. When Hist=TRUE the
model returns the historical simulations only.CheckConverg has been deprecated - use
Converge now to check MSE for convergencecustompars section in runMSE.r and
renamed parameters to match OM objectR0 can be a vector
nsim longcustompars has been moved in the MSE code so that more
parameters can be passed in to the MSE. A message alerts users which
valid parameters have been found in custompars and any
invalid parameters are displayed in a warning messageBMSY_B0 to
SSBMSY_SSB0 to avoid confusionSSB and
vulnerable biomass VB to MSE objectSpAbun slot to data object for abundance of
spawning stock. The Abun slot relates to vulnerable
biomassntrials and fracD control arguments
to runMSE. Allows user to modify the maximum number of
re-samples in the optimization to achieve the sampled depletion. The
model will stop if a proportion greater than fracD of the
simulated depletion values are not the same as the sampled values after
more than ntrials re-samplesgetr functionChooseEffort function where nyears was
being set to 0 in some casesPplot2 for F/FMSYhcv is 0 in
the runMSE codeFMSYref
results in exactly F/FSMY = 1maxF now also applies to the catch that is taken from
the population