Groups keyboard shortcuts have been updated
Dismiss
See shortcuts

Tab 4.3 Setting a behavioural threshold to generate 95 PPU for separate variables

46 views
Skip to first unread message

Rodhrai Crowley

unread,
Oct 30, 2024, 3:30:03 PM10/30/24
to R-SWAT
Hi Tam,

I am using R-SWAT to run simulations of river flow and suspended sediment loads. 

I have selected the NSE as the objective function in my case. The NSE value for what we would consider a behavioural simulation of flow and what we would consider a behavioural simulation of sediment are different. 

I have noticed that the behavioural threshold specified in tab 4.3. 'Optimization/Uncertainty' of the R-SWAT interface is applied to the upper table in the image below. I calculate the objective function values in this table to be the average of the objective function value for the flow and sediment variables from each simulation. See below, the average NSE, the NSE of the flow (var_1) and suspended sediment load (var_2) for the validation period of SimNr 1 (red circle around values).



I looked at the code in the objFunction.R file, and lines 347-349 of this file seem to point to this observation. 

However, I want to specify separate behavioural thresholds for flow and sediment simulations, that are applied separately to the objective function values for the different variables rather than the average objective function value for simulation of the two variables in each simulation. This would mean that the behavioural threshold is applied to the lower table in the image above (to the separate objective function values for the different variables). 

Have you or anyone else in this group experienced a similar issue, and have you found a way or modified the code to resolve it?

Best wishes,

Rodhraí

 


Tam Nguyen

unread,
Oct 30, 2024, 3:46:28 PM10/30/24
to R-SWAT
There are several ways that you can do it dependings on whether you want to change the code or not, example:

1. If you don't want to change the code: you just export the table of objective function values for each variables (as shown in your 2nd figure) and select the simulation number which have the objective function values for flow and sediment that meet your criteria => Then you export the parameter values and rerun your whole model ONLY with the parameter set that meet your criteria (use option run model with parameter from external file) => after rerun your model, just define all output simulations are behavioral simulations (by using very low behavioral threshold, example, -99999)

2. If you want to change the code: need to search and modify the function to calculate 95PPU and reinstall RSWAT package from your local code

Rodhrai Crowley

unread,
Nov 14, 2024, 5:57:39 PM11/14/24
to R-SWAT
Hi Tam,

Thank you for your suggestions, much appreciated.

Best wishes,

Rodhraí

Reply all
Reply to author
Forward
0 new messages