You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
just three comments that could improve the code (and/or the information provided in the manual). While trying to condition FLBEIA 1.15.5 with R4.1 we encountered the following issues:
For biomass dynamic stocks the "create.biols.data.r" requires that age.min=age.max=NA,
for the following line of code in function "create.list.stks.flqa" to run (otherwise there is a problem when checking dimensions):
stk.flqa <- FLQuant(dimnames = list(age = 'all', year = nmy, unit = nmu, season = nms, iter = 1:ni))
However "create.fleets.data.r" requires: age.min-age.max =0 otherwise this error message appears: "Error in if (stk.age.max - stk.age.min == 0) { : missing value where TRUE/FALSE needed"
Although the "catch.threshold" is not a required field in fleets.ctrl for fixedEffort model (according to the manual),
the function "CorrectCatch.r" requires it.
The same is true for "discard.TAC.OS", which should be set to "FALSE" in a fixedEffort model without TACs. If not set (and TACs are not provided), the code produces an error within function "ageBased.CobbDouglas.r", while executing the following "if" statement and line: tac <- (advice$TAC[st,yr]*QS)[drop=T]" # it
Hello,
just three comments that could improve the code (and/or the information provided in the manual). While trying to condition FLBEIA 1.15.5 with R4.1 we encountered the following issues:
for the following line of code in function "create.list.stks.flqa" to run (otherwise there is a problem when checking dimensions):
stk.flqa <- FLQuant(dimnames = list(age = 'all', year = nmy, unit = nmu, season = nms, iter = 1:ni))
However "create.fleets.data.r" requires: age.min-age.max =0 otherwise this error message appears: "Error in if (stk.age.max - stk.age.min == 0) { : missing value where TRUE/FALSE needed"
Although the "catch.threshold" is not a required field in fleets.ctrl for fixedEffort model (according to the manual),
the function "CorrectCatch.r" requires it.
The same is true for "discard.TAC.OS", which should be set to "FALSE" in a fixedEffort model without TACs. If not set (and TACs are not provided), the code produces an error within function "ageBased.CobbDouglas.r", while executing the following "if" statement and line: tac <- (advice$TAC[st,yr]*QS)[drop=T]" # it
if(TACOS){
yr.share <- advice$quota.share[[stknm]][flnm,yr,, drop=T] # [it]
ss.share <- fleets.ctrl$seasonal.share[[stknm]][flnm,yr,,ss, drop=T] # [it]
QS <- yr.share*ss.share # [it]
QS[is.na(QS)] <- 0
tac <- (advice$TAC[st,yr]*QS)[drop=T] # it
}
So it would be good to include this in the manual, i.e. that "discard.TAC.OS" should be specified in fleets.ctrl also for the fixedEffort model.
Thanks,
Vicky
The text was updated successfully, but these errors were encountered: