From 301a27683c49a95b2ad017b53b4630834cb6871e Mon Sep 17 00:00:00 2001 From: Delaigue Olivier <olivier.delaigue@irstea.fr> Date: Sat, 17 Jul 2021 02:47:36 +0200 Subject: [PATCH] docs(man): add an example about the use of the 'AxisTS' argument of the plot.OutputsModel function Refs #122 --- man/plot.OutputsModel.Rd | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/man/plot.OutputsModel.Rd b/man/plot.OutputsModel.Rd index 10c033c9..239ca8a2 100644 --- a/man/plot.OutputsModel.Rd +++ b/man/plot.OutputsModel.Rd @@ -136,6 +136,15 @@ plot(simGR4J$OutputsModel, Qobs = simGR4J$Qobs, LayoutHeights = c(0.5, 1, 1)) +### customize x-axis on time series plot +FunAxisTS <- function(x) { + axis.POSIXct(side = 1, x = x$DatesR, + at = pretty(x$DatesR, n = 10), + format = "\%Y-\%m-\%d") +} +plot(simGR4J$OutputsModel, Qobs = simGR4J$Qobs, AxisTS = FunAxisTS) + + ### add a main title ## the whole list of settable par's -- GitLab