Commit 1a28e685 authored by Delaigue Olivier's avatar Delaigue Olivier
Browse files

refactor(pot.OutputsModel): replace the use of 'if' by 'else if' in order to check the time step

Resf #122
Showing with 3 additions and 6 deletions
+3 -6
......@@ -168,18 +168,15 @@ plot.OutputsModel <- function(x, Qobs = NULL, IndPeriod_Plot = NULL, BasinArea =
BOOL_TS <- TRUE
NameTS <- "hour"
plotunit <- "[mm/h]"
}
if (inherits(OutputsModel, "daily")) {
} else if (inherits(OutputsModel, "daily")) {
BOOL_TS <- TRUE
NameTS <- "day"
plotunit <- "[mm/d]"
}
if (inherits(OutputsModel, "monthly")) {
} else if (inherits(OutputsModel, "monthly")) {
BOOL_TS <- TRUE
NameTS <- "month"
plotunit <- "[mm/month]"
}
if (inherits(OutputsModel, "yearly")) {
} else if (inherits(OutputsModel, "yearly")) {
BOOL_TS <- TRUE
NameTS <- "year"
plotunit <- "[mm/y]"
......
Supports Markdown
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