updateAmount.RdThis function updates the catch amount of a totalfleet object.
updateAmount(fleetName, year, step, area, value)
| fleetName | a string of the fleet name |
|---|---|
| year | a target year |
| step | a target step |
| area | a target area |
| value | the target amount |
a vector of numeric error codes (0 is success, otherwise is error)
if (FALSE) { if(interactive()){ exPath <- loadExample() initGadget(exPath, "refinputfile") updateAmount("future", 1978, 1, 1, 123456) updateAmount("future", 1978, 3, 1, 567890) stat <- runStep() print(sum(stat$fleets$future$catch$had[, "biomassConsumed"])) print(aggregate(biomassConsumed ~ year + step, data = stat$fleets$future$catch$had, FUN=sum)) endGadget() } }