Description Usage Arguments Details
View source: R/update_data_and_predict.R
This is the main function. It is assumed to be run on a daily basis. It downloads current rain and flow data, does a simple validation of the data, prepares the data for the model and runs the model to predict the water quality.
1 2 3 4 5 | update_data_and_predict(
day_string = as.character(Sys.Date()),
upload = FALSE,
dbg = 1
)
|
day_string |
day for which to predict the water quality, in format
yyyy-mm-dd, e.g. "2019-07-01". Default: |
upload |
logical. If |
dbg |
debug level. The higher the value, the more verbose the output |
The following environment variables need to be set:
URL to KWB's download FTP server
URL to Senate's download FTP server
URL to TSB's upload server
User name and password for KWB's download FTP server
User name and password for Senate's download FTP server
User name and password for TSB's upload server
You may use usethis::edit_r_environ()
to open the .Renviron file in
which you can add the corresponding assignments.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.