sizespectrum / mizerExperimental

Extends the mizer package with experimental features
https://sizespectrum.org/mizerExperimental/
3 stars 5 forks source link

polishing `getYieldVsFcurve()` #6

Open gustavdelius opened 4 years ago

gustavdelius commented 4 years ago

Ken Andersen has contributed a function getYieldVsFcurve(), see https://sizespectrum.org/mizerExperimental/reference/getYieldVsFcurve.html. There are some things that should be fixed before it is moved to core:

The following would be good to implement:

gustavdelius commented 3 years ago

@Kenhasteandersen Hi Ken, I would like to polish your yield curve function. Currently it only works in very specific circumstances, namely when the target species is selected by only one gear and that gear also selects another species. Otherwise one gets an error message. Clearly that requirement that the gear also selects other species I can fix by fixing the code. But I have a question about what the function should do in the case where a species is selected by several gears. Here is one proposal:

For each gear selecting the target species create two copies of that gear with the same selectivities and catchabilities but make one copy only select the target species and the other copy only select the remaining species. Then vary the effort of the copy that selects only the target species and keep all other efforts the same.

Is that how you would do it? An alternative would be to make the yield curve gear-specific, i.e., leave the fishing by all other gears unaffected, even if they also select the target species.

Kenhasteandersen commented 3 years ago

Hi Gustav,

Great that you want to fix the code.

What I wanted was to only fish on the target species and leave all the other unaffected. The only way the gear enters is on the size selectivity on the target species. The curve can then be used to estimate the MSY of just that one species in an idealised context.

Another variant would be a function that only varies one gear (and possibly selects multiple species) while keeping the other gears fixed.

Does that answer your question?

Ken

For each gear selecting the target species create two copies of that gear with the same selectivities and catchabilities but make one copy only select the target species and the other copy only select the remaining species. Then vary the effort of the copy that selects only the target species and keep all other efforts the same.

Is that how you would do it? An alternative would be to make the yield curve gear-specific, i.e., leave the fishing by all other gears unaffected, even if they also select the target species.

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHubhttps://github.com/sizespectrum/mizerExperimental/issues/6#issuecomment-733505998, or unsubscribehttps://github.com/notifications/unsubscribe-auth/ADFHLAKLYCEWPGXWGCELZFDSRSSSZANCNFSM4MZVRX5A.

gustavdelius commented 3 years ago

A few weeks ago I fixed some of the issues. There are now two functions: getYieldVsF() and plotYieldVsF(). I only just got around to committing those changes.

gustavdelius commented 2 years ago

Hi @baldrech, you have done a lot on this issue and this has been merged in pull request https://github.com/sizespectrum/mizerExperimental/pull/43 . Can you give an update on the current status of the work?

I notice that there are currently some undocumented arguments in several functions which leads to errors when checking the package. Would you be able to complete the documentation?

Many thanks, Gustav

SamikDatta commented 1 year ago

Hi @gustavdelius - I have modified the function plotYieldVsF on my branch, as it is currently not working (the variable for x should be effort but it is currently F). Shall I push this change to the repo?

gustavdelius commented 1 year ago

Hi Samik. Yes, please create a pull request.