diff --git a/DESCRIPTION b/DESCRIPTION index 49d5f7fb298e46d3456ff41d8db3a858f8c1ce1d..c20567ddc07b98e0ea14ce492d570a677b0249dc 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -1,8 +1,8 @@ Package: airGRteaching Type: Package Title: Teaching Hydrological Modelling with the GR Rainfall-Runoff Models ('Shiny' Interface Included) -Version: 0.2.10.17 -Date: 2020-04-17 +Version: 0.2.10.18 +Date: 2020-04-18 Authors@R: c( person("Olivier", "Delaigue", role = c("aut", "cre"), comment = c(ORCID = "0000-0002-7668-8468"), email = "airGR@inrae.fr"), person("Laurent", "Coron", role = c("aut"), comment = c(ORCID = "0000-0002-1503-6204")), diff --git a/NEWS.md b/NEWS.md index 60a0248f8a219113227ef9370a3f7e590228c3e2..78f3ffe16b5fbb598303eacabda59d86e7fb590d 100644 --- a/NEWS.md +++ b/NEWS.md @@ -4,7 +4,7 @@ -### 0.2.10.17 Release Notes (2020-04-17) +### 0.2.10.18 Release Notes (2020-04-17) #### New features diff --git a/R/Utils.R b/R/Utils.R index 0e932fd90b44528ed53901f2154f81510482a00d..2e737d4b454771ba9d6cf12b79d2fb69bf57b4d2 100644 --- a/R/Utils.R +++ b/R/Utils.R @@ -315,8 +315,11 @@ if (getRversion() >= "2.15.1") { text(x = xy_P[1]+50, y = y_interception+20, labels = "Interception", pos = 4, font = 1, cex = 1.4) } + # E vers Es et P vers Ps ou Pn + y_Xs <- ifelse(HydroModel == "GR2M", y_rendement+2*tmp_decal, y_interception+tmp_decal) + # P vers Pn - segments(x0 = xy_P[1], x1 = xy_P[1], y0 = xy_P[2], y1 = y_interception+tmp_decal) + segments(x0 = xy_P[1], x1 = xy_P[1], y0 = xy_P[2], y1 = y_Xs) # Pn vers Ps segments(x0 = xy_P[1], x1 = xy_P[1], @@ -338,7 +341,7 @@ if (getRversion() >= "2.15.1") { # E vers En puis Es segments(x0 = xy_E[1], x1 = xy_E[1], - y0 = xy_E[2], y1 = y_interception+tmp_decal) + y0 = xy_E[2], y1 = y_Xs) segments(x0 = xy_E[1], x1 = xy_E[1], y0 = y_interception, y1 = y_rendement) @@ -437,15 +440,16 @@ if (getRversion() >= "2.15.1") { # parametres tmp_decal <- (y_percolation - y_entreeUH) / 2 - # Pr vers UH + # Pr vers UH (Pr vers reservoir de routage si GR2M) + k <- ifelse(HydroModel == "GR2M", 0.5, 1) segments(x0 = x_PnPs, x1 = x_PnPs, - y0 = y_percolation, y1 = y_entreeUH+tmp_decal/2) + y0 = y_percolation, y1 = (y_entreeUH*k) + tmp_decal/2) if (HydroModel == "GR2M") { - # Pr plotrix::boxed.labels(x = x_PnPs, y = y_percolation, labels = "Pr", bg = col_mod_bg, border = NA, xpad = xpad, ypad = ypad) + if (OutputsModel$PR[i_pdt] != 0) { points(x = x_PnPs[1], y = y_entreeUH+tmp_decal, type = "p", pch = tri_B, col = col_P, @@ -652,6 +656,7 @@ if (getRversion() >= "2.15.1") { # Reservoir de routage if (HydroModel == "GR2M") { + xy_min_ROUT[1] <- x_PnPs - base_res/2 Param[3] <- 600 } rect(xleft = xy_min_ROUT[1], xright = xy_min_ROUT[1]+base_res,