En raison du déménagement des baies serveurs, les services gitlab.irstea.fr et mattermost.irstea.fr seront interrompus le samedi 2 octobre 2021 au matin. Ils devraient revenir à la normale dans la journée.

Commit 8b1f616d authored by unknown's avatar unknown
Browse files

v0.2.0.8 bug fixed in ShinyGR when a vector is given to the HypsoData argument

parent ee4b1928
Package: airGRteaching
Type: Package
Title: Teaching Hydrological Modelling with GR (Shiny Interface Included)
Version: 0.2.0.7
Version: 0.2.0.8
Date: 2018-03-14
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)
......
......@@ -2,7 +2,7 @@
## 0.2.0.7 Release Notes (2018-03-14)
## 0.2.0.8 Release Notes (2018-03-14)
CRAN-compatibility updates
- embeding dygraphs functions to avoid user to install the last version of this package from GitHub (import of devtools not necessary)
......
......@@ -5,7 +5,7 @@ ShinyGR <- function(ObsDF = NULL, DatesR = NULL, Precip = NULL, PotEvap = NULL,
if ((is.null(ObsDF) | any(sapply(ObsDF, is.null))) && (is.null(DatesR) | is.null(Precip) | is.null(PotEvap) | is.null(Qobs))) {
stop("Missing input data")
}
if (is.null(SimPer) | any(sapply(SimPer, is.null))) {
stop("Null values non suitable for 'SimPer'.")
}
......@@ -83,7 +83,9 @@ ShinyGR <- function(ObsDF = NULL, DatesR = NULL, Precip = NULL, PotEvap = NULL,
if (is.null(HypsoData)) {
HypsoData <- vector(mode = "list", length = lenObsDF)
} else {
HypsoData <- as.list(HypsoData)
if (!is.list(HypsoData)) {
HypsoData <- list(HypsoData)
}
if (length(HypsoData) == lenObsDF) {
HypsoData <- as.list(HypsoData)
} else if(length(HypsoData) > lenObsDF) {
......@@ -97,7 +99,7 @@ ShinyGR <- function(ObsDF = NULL, DatesR = NULL, Precip = NULL, PotEvap = NULL,
}
}
names(HypsoData) <- NamesObsBV
if (is.null(NLayers)) {
NLayers <- vector(mode = "list", length = lenObsDF)
} else {
......
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