Commit a8b7afa3 authored by unknown's avatar unknown
Browse files

v0.1.11.7 new main managment for plot.CalGR function

parent d5177a69
Package: airGRteaching
Type: Package
Title: Tools to Simplify the Use of the airGR Hydrological Package for Education (Including a Shiny Interface)
Version: 0.1.11.6
Version: 0.1.11.7
Date: 2018-01-29
Authors@R: c(person("Olivier", "Delaigue", role = c("aut", "cre"), email = "airGR@irstea.fr"), person("Laurent", "Coron", role = c("aut")), person("Pierre", "Brigode", role = c("aut")), person("Guillaume", "Thirel", role = c("ctb")))
Depends: airGR (>= 1.0.9.43)
......
......@@ -5,7 +5,7 @@ plot.CalGR <- function(x, xlab = NULL, ylab = NULL, main = NULL, which = c("per
}
if (! any(which %in% c("perf", "iter", "ts"))) {
stop("Non convenient data for which argument. Must be of class \"perf\", \"iter\" or \"ts\"")
}
}
nbParamX <- .TypeModelGR(x)$NbParam #as.numeric(gsub("\\D", "", x$TypeModel))
nbParamC <- ifelse(.TypeModelGR(x)$CemaNeige, 2, 0)
......@@ -52,7 +52,7 @@ plot.CalGR <- function(x, xlab = NULL, ylab = NULL, main = NULL, which = c("per
ParamLab$Label <- gsub("TimeUnit", substr(.TypeModelGR(x)$TimeUnit, 1, 1), ParamLab$Label)
par(mar = c(2.5, 3.5, 4.5, 1), mgp = c(2.0, 0.6, 0))
par(mar = c(2.5, 3.5, 2.0, 1.0), mgp = c(2.0, 0.6, 0.0), oma = c(0, 0, 4, 0))
for (i in seq_len(ncol(x$OutputsCalib$HistParamR))) {
plot(x$OutputsCalib$HistParamR[, i],
col = ifelse(grepl("X", nmParam[i]), "darkorchid3", "darkolivegreen3"),
......@@ -64,7 +64,11 @@ plot.CalGR <- function(x, xlab = NULL, ylab = NULL, main = NULL, which = c("per
col = "tomato",
type = "b", pch = 19, cex = 1.0,
xlab = "", ylab = "",
main = sprintf("Efficiency criteria (%s)\nduring the steepest-descent step", gsub(".*_", "", x$CalCrit)))
main = gsub(".*_", "", x$CalCrit))
mainIter <- "Evolution of parameters and efficiency criterion\nduring the iterations of the steepest-descent step"
title(main = ifelse(is.null(main), mainIter, main),
outer = TRUE, line = 0.6, cex.main = 1.6)
}
if (any(which[1L] %in% c("ts"))) {
......
Markdown is supported
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