When comparing OLW2015 scenario SCAMP input data with the calibration SCAMP input data, some values had changed in Fiordland area where the scenario didn't apply.
It turns out that missing leach rate data in the LeachRateRaster data (associated with water bodies) was allocated the minimum leach rate value when the diffuse input data was being prepared.
Digging deeper, it seems that the LeachRateRasterCreator() function doesn't populate cells which are NA in the slope, soil drainage or precipitation/irrigation spatial data. These are all the water areas. The leach rate look up table includes a value for water which is supposed to apply to "All" predictor cases. However it doesn't. This leads to missing leach rate values in the leach rate raster. These missing values are then assigned to the minimum leach rate value when building the diffuse inputs data. Specifically the allocation using the minimum occurs when the DiffuseLoadTableCreator() function is called (part of the CASMPrePostProcessor package.
So the LeachRateRasterCreator() function needs to be changed so that there are no NA cells, and the DiffuseLoadTableCreator() should fail with an appropriate error message if there are NA values.
When comparing OLW2015 scenario SCAMP input data with the calibration SCAMP input data, some values had changed in Fiordland area where the scenario didn't apply. It turns out that missing leach rate data in the LeachRateRaster data (associated with water bodies) was allocated the minimum leach rate value when the diffuse input data was being prepared. Digging deeper, it seems that the LeachRateRasterCreator() function doesn't populate cells which are NA in the slope, soil drainage or precipitation/irrigation spatial data. These are all the water areas. The leach rate look up table includes a value for water which is supposed to apply to "All" predictor cases. However it doesn't. This leads to missing leach rate values in the leach rate raster. These missing values are then assigned to the minimum leach rate value when building the diffuse inputs data. Specifically the allocation using the minimum occurs when the DiffuseLoadTableCreator() function is called (part of the CASMPrePostProcessor package.
So the LeachRateRasterCreator() function needs to be changed so that there are no NA cells, and the DiffuseLoadTableCreator() should fail with an appropriate error message if there are NA values.