Commit d6b5fc88 authored by Delaigue Olivier's avatar Delaigue Olivier Committed by Dorchies David
Browse files

v1.4.4.23 BUG: SeriesAggreg now runs when there is only one column to convert # 41

parent 6da405c2
Package: airGR
Type: Package
Title: Suite of GR Hydrological Models for Precipitation-Runoff Modelling
Version: 1.4.4.22
Version: 1.4.4.23
Date: 2020-04-20
Authors@R: c(
person("Laurent", "Coron", role = c("aut", "trl"), comment = c(ORCID = "0000-0002-1503-6204")),
......
......@@ -36,7 +36,7 @@ SeriesAggreg2 <- function(TabSeries, Format, TimeFormat, NewTimeFormat, ConvertF
TabSeries[[1L]] <- as.POSIXct(TabSeries[[1L]])
}
## check TabSeries other columns (boolean converted to numeric)
apply(TabSeries[, -1L], MARGIN = 2, FUN = function(iCol) {
apply(TabSeries[, -1L, drop = FALSE], MARGIN = 2, FUN = function(iCol) {
if (!is.numeric(iCol)) {
stop("'TabSeries' columns (other than the first one) must be of numeric class")
}
......
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