When sim$RTMLarge has been supplied by another module (but RTM has not), the previous code was stopping even though the object already existed in sim. It was also not using RTML to make rawBiomassMap, which it should as RTMLarge should be the source of information for projection, extent, resolution, etc.
The changes proposed here:
make the stop if suppliedElsewhere("rasterToMatchLarge", sim) == TRUE AND is.null(sim$rasterToMatchLarge) == TRUE
use RTML (when available) as the template for rawBiomassMap creation.
When sim$RTMLarge has been supplied by another module (but RTM has not), the previous code was stopping even though the object already existed in sim. It was also not using RTML to make rawBiomassMap, which it should as RTMLarge should be the source of information for projection, extent, resolution, etc.
The changes proposed here:
suppliedElsewhere("rasterToMatchLarge", sim) == TRUE
ANDis.null(sim$rasterToMatchLarge) == TRUE