Open mle2718 opened 1 year ago
I've fixed it get_fillRepArrays
by moving some of the problematic outputs into an if(y>=fmyearIdx)
conditional.
A placeholder to remind me to cherry-pick this from EconOnly2 over to Dev?
96210282bdc14653e45bd4951f545d42abc0e5d9
RPmat is NA until the first time a stock assessment is run. This doesn't happen until y>=fmyearIdx
https://github.com/lkerr/groundfish-MSE/blob/ea59c71d82db906bd7f280c4390809ba0b5c8c86/processes/runSim.R#L82-L89
When runSim.R calls get_fillRepArrays.R, this causes me some problems.
Line 43 here is causing me some problems. https://github.com/lkerr/groundfish-MSE/blob/ea59c71d82db906bd7f280c4390809ba0b5c8c86/functions/datawrangling/get_fillRepArrays.R#L39-L47
I'm not good enough at R to figure out if this problem is due to length(stock$res$F.report) being 0, if stock$res$F.report is NULL or because RPmat[,1][y] is NULL. I can 'fix this' by only running get_fillRepArrays.R when year>=fmyearIdx, but this is not idea.