Error in data extraction in R-SWAT

182 views
Skip to first unread message

JULIO CESAR ANGELO BORGES

unread,
Mar 20, 2023, 3:29:20 PM3/20/23
to R-SWAT
Hi!

I'm having some problem getting the correct data in R-SWAT.
After finishing my simulation (in SWAT+) I identified the stream/reach that I would like to calibrate (cha0402), but when I inform column 48 (flo_out) and reach 402 to be extracted by R-SWAT, the data that are presented (graphs) are not correct. The data presented in the QSWAT+ data view for stream 402 are of completely different orders from those shown in the R-SWAT graph (as shown in the attached photos).
How should I proceed to correctly identify the reach/stream I want to calibrate?

Thank you all!
rswat_data.png
qswat+_data_vs_observed_data.png

Tam Nguyen

unread,
Mar 21, 2023, 5:25:29 AM3/21/23
to R-SWAT
could you share your channel output at monthly here? 
Message has been deleted

JULIO CESAR ANGELO BORGES

unread,
Mar 21, 2023, 6:30:09 AM3/21/23
to R-SWAT
the first file (flo_out_402_mon) corresponds to the QSWAT+ output, the second (flo_out_vs_obs) contains the observed vs simulated data to be compared
flo_out_vs_obs.xlsx
flo_out_402_mon.csv

Tam Nguyen

unread,
Mar 23, 2023, 2:33:16 PM3/23/23
to R-SWAT
Hi the file that your share is not "channel_sd_mon.txt", Could you share again this file "channel_sd_mon.txt" then I can check it out

JULIO CESAR ANGELO BORGES

unread,
Mar 23, 2023, 2:47:55 PM3/23/23
to R-SWAT
Hi, sorry, I didn't understand. The compressed file exceeds the 24mb limit. It's in this drive link.
Thanks.

Tam Nguyen

unread,
Mar 25, 2023, 3:23:25 PM3/25/23
to R-SWAT
Hi, you are right, this is the error in R-SWAT, I have updated the tool, just download again from github and it will work

JULIO CESAR ANGELO BORGES

unread,
Mar 25, 2023, 8:24:09 PM3/25/23
to R-SWAT
Hi! I downloaded it and tested it and it's still the same as before...
besides downloading the updated file, do I need to do something to any of the swat+ output files?

Tam Nguyen

unread,
Mar 26, 2023, 1:45:54 AM3/26/23
to R-SWAT
Hi, It should work (I tested with the example SWAT+ project and it works). Could you try again, delete R-SWAT and download and test again. If you still have the same problem, just send me your TxtInOut folder. You don't have to do anything with SWAT+ output files

JULIO CESAR ANGELO BORGES

unread,
Mar 26, 2023, 1:48:20 PM3/26/23
to R-SWAT
Hi,
I uninstalled RStudio and R, cleaned all packages and deleted all RSWAT related files before downloading the update... installed and tested it three times and every time the results were the same as before. I hope you can identify the error, I am very hopeful of your help

Message has been deleted

Tam Nguyen

unread,
Mar 29, 2023, 12:18:12 PM3/29/23
to R-SWAT
It works in my case, I run again and didn't see any issue, here the outputs (reach 402, column 48) are the same if i check manually and compared with R-SWAT output

Core_1.7z

JULIO CESAR ANGELO BORGES

unread,
Mar 29, 2023, 3:23:47 PM3/29/23
to R-SWAT
Hi Tam,
Thank you very much, this support has been of great help. I will test as recommended.

Abu Zafor

unread,
Apr 19, 2023, 6:49:10 PM4/19/23
to R-SWAT
JULIO CESAR ANGELO BORGES
did you solve the problem?

JULIO CESAR ANGELO BORGES

unread,
Apr 19, 2023, 7:22:37 PM4/19/23
to R-SWAT
Hello Abu Zafor, look in your channel_sd_***.txt file and look for the reach number you want to calibrate in the column "name", see if the number in the column  "unit" is the same, if they are not the same, use the number in the unit column in rswat and do the test. In my case the numbers were cha0402 (column name) and 335 (column unit), so I managed to extract the data correctly. 
Hope it works.

Md. Abu Zafor

unread,
Apr 19, 2023, 10:13:43 PM4/19/23
to R-SWAT
THank you so much CESAR for your quick reply. Would you please share a screen shot or a video with me.?
Thanks and regards

Md. Abu Zafor

unread,
Apr 20, 2023, 11:32:47 PM4/20/23
to R-SWAT

JULIO CESAR ANGELO BORGES you shared a pdf file with me.but i did not find it.
Reply all
Reply to author
Forward
0 new messages