Commit 4458848b authored by Delaigue Olivier's avatar Delaigue Olivier
Browse files

v1.0.10.5 typo revision of the example of the RunModel_GR4H doc

Showing with 13 additions and 13 deletions
+13 -13
Package: airGR Package: airGR
Type: Package Type: Package
Title: Suite of GR Hydrological Models for Precipitation-Runoff Modelling Title: Suite of GR Hydrological Models for Precipitation-Runoff Modelling
Version: 1.0.10.4 Version: 1.0.10.5
Date: 2018-05-22 Date: 2018-05-22
Authors@R: c( Authors@R: c(
person("Laurent", "Coron", role = c("aut", "trl")), person("Laurent", "Coron", role = c("aut", "trl")),
......
...@@ -14,7 +14,7 @@ output: ...@@ -14,7 +14,7 @@ output:
### 1.0.10.4 Release Notes (2018-05-22) ### 1.0.10.5 Release Notes (2018-05-22)
____________________________________________________________________________________ ____________________________________________________________________________________
......
...@@ -70,27 +70,27 @@ library(airGR) ...@@ -70,27 +70,27 @@ library(airGR)
data(L0123003) data(L0123003)
## preparation of the InputsModel object ## preparation of the InputsModel object
InputsModel <- CreateInputsModel(FUN_MOD=RunModel_GR4H,DatesR=BasinObs$DatesR, InputsModel <- CreateInputsModel(FUN_MOD = RunModel_GR4H, DatesR = BasinObs$DatesR,
Precip=BasinObs$P,PotEvap=BasinObs$E) Precip = BasinObs$P, PotEvap = BasinObs$E)
## run period selection ## run period selection
Ind_Run <- seq(which(format(BasinObs$DatesR,format="\%d/\%m/\%Y \%H:\%M")=="01/03/2004 00:00"), Ind_Run <- seq(which(format(BasinObs$DatesR, format = "\%d/\%m/\%Y \%H:\%M")=="01/03/2004 00:00"),
which(format(BasinObs$DatesR,format="\%d/\%m/\%Y \%H:\%M")=="31/12/2008 23:00")) which(format(BasinObs$DatesR, format = "\%d/\%m/\%Y \%H:\%M")=="31/12/2008 23:00"))
## preparation of the RunOptions object ## preparation of the RunOptions object
RunOptions <- CreateRunOptions(FUN_MOD=RunModel_GR4H,InputsModel=InputsModel,IndPeriod_Run=Ind_Run) RunOptions <- CreateRunOptions(FUN_MOD = RunModel_GR4H, InputsModel = InputsModel, IndPeriod_Run = Ind_Run)
## simulation ## simulation
Param <- c(521.113,-2.918,218.009,4.124) Param <- c(521.113, -2.918, 218.009, 4.124)
OutputsModel <- RunModel_GR4H(InputsModel=InputsModel,RunOptions=RunOptions,Param=Param) OutputsModel <- RunModel_GR4H(InputsModel = InputsModel, RunOptions = RunOptions, Param = Param)
## results preview ## results preview
plot(OutputsModel,Qobs=BasinObs$Qmm[Ind_Run]) plot(OutputsModel, Qobs = BasinObs$Qmm[Ind_Run])
## efficiency criterion: Nash-Sutcliffe Efficiency ## efficiency criterion: Nash-Sutcliffe Efficiency
InputsCrit <- CreateInputsCrit(FUN_CRIT=ErrorCrit_NSE,InputsModel=InputsModel, InputsCrit <- CreateInputsCrit(FUN_CRIT = ErrorCrit_NSE, InputsModel = InputsModel,
RunOptions=RunOptions,Qobs=BasinObs$Qmm[Ind_Run]) RunOptions = RunOptions, Qobs = BasinObs$Qmm[Ind_Run])
OutputsCrit <- ErrorCrit_NSE(InputsCrit=InputsCrit,OutputsModel=OutputsModel) OutputsCrit <- ErrorCrit_NSE(InputsCrit = InputsCrit, OutputsModel = OutputsModel)
} }
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment