StoXProject / RstoxFDA

Fisheries Dependent Analysis with Rstox
https://stoxproject.github.io/RstoxFDA
GNU Lesser General Public License v3.0
0 stars 1 forks source link

non-linear option: argument is of length zero #92

Closed edvinf closed 10 months ago

edvinf commented 1 year ago

When the non-linear option is chosen for ParameterizeReca, one will often get the error-message 'argument is of length zero' after the process has been running for a while. This was experiences when testing the optinon for Mackerell 2022-fishery, and NEA haddock for the 2022-fishery. The option is not necessarily intended to be used for either of these stocks. It may be a poor model fit, and may not converge, but we should be able to provide an error message consistent with other model failures if that happens.

edvinf commented 10 months ago

This turns out to be a bug in Reca. I have reported it to maintainers and will try to figure out a workaround.

edvinf commented 10 months ago

The flag old.version on GlobalParameters has been used in experimental Reca code, and a check for this remains in a piece of code executed if non-linear is chosen as lgamodel. It can safely be set to zero for executions of Reca, and I will implement a workaround that sets old.version on GlobalParameters before calling Reca. Future releases of Reca will remove any checks on old.version.