From 90b8fbadfe2b656afaeadcd01bf94413a93f8180 Mon Sep 17 00:00:00 2001 From: Delaigue Olivier <olivier.delaigue@irstea.priv> Date: Thu, 21 Mar 2019 08:40:22 +0100 Subject: [PATCH] v1.2.9.34 CLEAN: argument names added when FUN_CRIT is called in ErrorCrit --- DESCRIPTION | 2 +- NEWS.rmd | 2 +- R/ErrorCrit.R | 9 ++++++--- 3 files changed, 8 insertions(+), 5 deletions(-) diff --git a/DESCRIPTION b/DESCRIPTION index 63011b1d..b2c77fce 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -1,7 +1,7 @@ Package: airGR Type: Package Title: Suite of GR Hydrological Models for Precipitation-Runoff Modelling -Version: 1.2.9.33 +Version: 1.2.9.34 Date: 2019-03-21 Authors@R: c( person("Laurent", "Coron", role = c("aut", "trl"), comment = c(ORCID = "0000-0002-1503-6204")), diff --git a/NEWS.rmd b/NEWS.rmd index 6e4cff93..e89e0352 100644 --- a/NEWS.rmd +++ b/NEWS.rmd @@ -13,7 +13,7 @@ output: -### 1.2.9.33 Release Notes (2019-03-21) +### 1.2.9.34 Release Notes (2019-03-21) diff --git a/R/ErrorCrit.R b/R/ErrorCrit.R index 80a25770..5ea035f3 100644 --- a/R/ErrorCrit.R +++ b/R/ErrorCrit.R @@ -19,8 +19,8 @@ ErrorCrit <- function(InputsCrit, OutputsModel, FUN_CRIT, warnings = TRUE, verbo ## ----- Single criterion if (inherits(InputsCrit, "Single")) { - OutputsCrit <- InputsCrit$FUN_CRIT(InputsCrit, - OutputsModel, + OutputsCrit <- InputsCrit$FUN_CRIT(InputsCrit = InputsCrit, + OutputsModel = OutputsModel, warnings = warnings, verbose = verbose) } @@ -30,7 +30,10 @@ ErrorCrit <- function(InputsCrit, OutputsModel, FUN_CRIT, warnings = TRUE, verbo if (inherits(InputsCrit, "Multi") | inherits(InputsCrit, "Compo")) { listOutputsCrit <- lapply(InputsCrit, FUN = function(iInputsCrit) { - iInputsCrit$FUN_CRIT(iInputsCrit, OutputsModel, warnings = warnings, verbose = verbose) + iInputsCrit$FUN_CRIT(InputsCrit = iInputsCrit, + OutputsModel = OutputsModel, + warnings = warnings, + verbose = verbose) }) listValCrit <- sapply(listOutputsCrit, function(x) x[["CritValue"]]) -- GitLab