library(airGRteaching)
## data.frame of observed data
data(L0123001, package = "airGR")
BasinObs2 <- BasinObs[, c("DatesR", "P", "E", "Qmm", "T")]
## Preparation of observed data for modelling
PREP <- PrepGR(ObsDF = BasinObs2, HydroModel = "GR4J", CemaNeige = TRUE)
## Calibration step
CAL <- CalGR(PrepGR = PREP, CalCrit = "KGE2",
WupPer = NULL, CalPer = c("1990-01-01", "1993-12-31"))
## Structure of CalGR object
str(CAL)
## Parameter and criterion evolution during
## the steepest descent step of the calibration algorithm
plot(CAL, which = "iter")
## Plot diagnostics
plot(CAL)
## Static plot of observed and simulated time series
plot(CAL, which = "ts")
plot(CAL, which = c("Precip", "Flows"))
## Dynamic plot of observed and simulated time series
dyplot(CAL)
Run the code above in your browser using DataLab