From 9affb66eaa2336e47f0491ba9c0ab56795b23903 Mon Sep 17 00:00:00 2001 From: Delaigue Olivier <olivier.delaigue@irstea.fr> Date: Tue, 26 Jan 2021 20:34:43 +0100 Subject: [PATCH] v1.6.9.32 man: review style in many help pages --- DESCRIPTION | 4 ++-- man/CreateCalibOptions.Rd | 2 +- man/CreateInputsCrit.Rd | 8 ++++---- man/CreateRunOptions.Rd | 6 +++--- man/Param_Sets_GR4J.Rd | 4 ++-- man/RunModel_CemaNeige.Rd | 4 ++-- man/RunModel_CemaNeigeGR4H.Rd | 2 +- man/RunModel_CemaNeigeGR4J.Rd | 4 ++-- man/RunModel_CemaNeigeGR5H.Rd | 2 +- man/RunModel_CemaNeigeGR6J.Rd | 4 ++-- man/TransfoParam.Rd | 4 ++-- 11 files changed, 22 insertions(+), 22 deletions(-) diff --git a/DESCRIPTION b/DESCRIPTION index 52f2699b..e097255a 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -1,8 +1,8 @@ Package: airGR Type: Package Title: Suite of GR Hydrological Models for Precipitation-Runoff Modelling -Version: 1.6.9.31 -Date: 2021-01-25 +Version: 1.6.9.32 +Date: 2021-01-26 Authors@R: c( person("Laurent", "Coron", role = c("aut", "trl"), comment = c(ORCID = "0000-0002-1503-6204")), person("Olivier", "Delaigue", role = c("aut", "cre"), comment = c(ORCID = "0000-0002-7668-8468"), email = "airGR@inrae.fr"), diff --git a/man/CreateCalibOptions.Rd b/man/CreateCalibOptions.Rd index b418995a..c98ad748 100644 --- a/man/CreateCalibOptions.Rd +++ b/man/CreateCalibOptions.Rd @@ -80,7 +80,7 @@ CreateCalibOptions(FUN_MOD, FUN_CALIB = Calibration_Michel, Users wanting to use \code{FUN_MOD}, \code{FUN_CALIB} or \code{FUN_TRANSFO} functions that are not included in the package must create their own \code{CalibOptions} object accordingly. \cr -## ---- CemaNeige version +## --- CemaNeige version If \code{IsHyst = FALSE}, the original CemaNeige version from Valéry et al. (2014) is used. \cr If \code{IsHyst = TRUE}, the CemaNeige version from Riboust et al. (2019) is used. Compared to the original version, this version of CemaNeige needs two more parameters and it includes a representation of the hysteretic relationship between the Snow Cover Area (SCA) and the Snow Water Equivalent (SWE) in the catchment. The hysteresis included in airGR is the Modified Linear hysteresis (LH*); it is represented on panel b) of Fig. 3 in Riboust et al. (2019). Riboust et al. (2019) advise to use the LH* version of CemaNeige with parameters calibrated using an objective function combining 75 \% of KGE calculated on discharge simulated from a rainfall-runoff model compared to observed discharge and 5 \% of KGE calculated on SCA on 5 CemaNeige elevation bands compared to satellite (e.g. MODIS) SCA (see Eq. (18), Table 3 and Fig. 6). Riboust et al. (2019)'s tests were realized with GR4J as the chosen rainfall-runoff model. \cr diff --git a/man/CreateInputsCrit.Rd b/man/CreateInputsCrit.Rd index 848a35fd..eed50f03 100644 --- a/man/CreateInputsCrit.Rd +++ b/man/CreateInputsCrit.Rd @@ -73,11 +73,11 @@ To calculate composite or multiple criteria, it is necessary to use the \code{Er \details{ Users wanting to use \code{FUN_CRIT} functions that are not included in the package must create their own InputsCrit object accordingly. \cr \cr -## ---- Period of calculation +## --- Period of calculation Criteria can be calculated over discontinuous periods (i.e. only over winter periods, or when observed discharge is below a certain threshold). To do so, please indicate in \code{Bool_Crit} which indices must be used for calcullation. Discontinuous periods are allowed in the \code{Bool_Crit} argument. -## ---- Transformations +## --- Transformations Transformations are simple functions applied to the observed and simulated variables used in order to change their distribution. Transformations are often used in hydrology for modifying the weight put on errors made for high flows or low flows. The following transformations are available: \cr \cr \itemize{ @@ -93,11 +93,11 @@ We do not advise computing KGE or KGE' with log-transformation as it might be wr In order to make sure that KGE and KGE2 remain dimensionless and are not impacted by zero values, the Box-Cox transformation (\code{transfo = "boxcox"}) uses the formulation given in Equation 10 of Santos et al. (2018). Lambda is set to 0.25 accordingly. \cr \cr The syntax of the power transformation allows a numeric or a string of characters. For example for a squared transformation, the following can be used: \code{transfo = 2}, \code{transfo = "2"} or \code{transfo = "^2"}. Negative values are allowed. Fraction values are not allowed (e.g., \code{"-1/2"} must instead be written \code{"-0.5"}).\cr \cr -## ---- The epsilon value +## --- The epsilon value The epsilon value is useful when \code{"log"} or \code{"inv"} transformations are used (to avoid calculation of the inverse or of the logarithm of zero). If an epsilon value is provided, then it is added to the observed and simulated variable time series at each time step and before the application of a transformation. The epsilon value has no effect when the \code{"boxcox"} transformation is used. The impact of this value and a recommendation about the epsilon value to use (usually one hundredth of average observation) are discussed in Pushpalatha et al. (2012) for NSE and in Santos et al. (2018) for KGE and KGE'. \cr \cr -## ---- Single, multiple or composite criteria calculation +## --- Single, multiple or composite criteria calculation Users can set the following arguments as atomic or list: \code{FUN_CRIT}, \code{Obs}, \code{VarObs}, \code{BoolCrit}, \code{transfo}, \code{Weights}. If the list format is chosen, all the lists must have the same length. \cr Calculation of a single criterion (e.g. NSE computed on discharge) is prepared by providing to \code{CreateInputsCrit} arguments atomics only. \cr diff --git a/man/CreateRunOptions.Rd b/man/CreateRunOptions.Rd index 6ed188c4..20859d4c 100644 --- a/man/CreateRunOptions.Rd +++ b/man/CreateRunOptions.Rd @@ -72,11 +72,11 @@ CreateRunOptions(FUN_MOD, InputsModel, Users wanting to use \code{FUN_MOD} functions that are not included in the package must create their own \code{RunOptions} object accordingly. -## ---- IndPeriod_WarmUp and IndPeriod_Run +## --- IndPeriod_WarmUp and IndPeriod_Run Since the hydrological models included in airGR are continuous models, meaning that internal states of the models are propagated to the next time step, \code{IndPeriod_WarmUp} and \code{IndPeriod_Run} must be continuous periods, represented by continuous indices values; no gaps are allowed. To calculate criteria or to calibrate a model over discontinuous periods, please see the \code{Bool_Crit} argument of the \code{\link{CreateInputsCrit}} function. -## ---- Initialisation options +## --- Initialisation options The model initialisation options can either be set to a default configuration or be defined by the user. @@ -111,7 +111,7 @@ However, it is also possible to perform a long-term initialisation if other indi } } -## ---- CemaNeige version +## --- CemaNeige version If \code{IsHyst = FALSE}, the original CemaNeige version from Valéry et al. (2014) is used. \cr If \code{IsHyst = TRUE}, the CemaNeige version from Riboust et al. (2019) is used. Compared to the original version, this version of CemaNeige needs two more parameters and it includes a representation of the hysteretic relationship between the Snow Cover Area (SCA) and the Snow Water Equivalent (SWE) in the catchment. The hysteresis included in airGR is the Modified Linear hysteresis (LH*); it is represented on panel b) of Fig. 3 in Riboust et al. (2019). Riboust et al. (2019) advise to use the LH* version of CemaNeige with parameters calibrated using an objective function combining 75 \% of KGE calculated on discharge simulated from a rainfall-runoff model compared to observed discharge and 5 \% of KGE calculated on SCA on 5 CemaNeige elevation bands compared to satellite (e.g. MODIS) SCA (see Eq. (18), Table 3 and Fig. 6). Riboust et al. (2019)'s tests were realized with GR4J as the chosen rainfall-runoff model. \cr diff --git a/man/Param_Sets_GR4J.Rd b/man/Param_Sets_GR4J.Rd index 7a3abb7c..5798b295 100644 --- a/man/Param_Sets_GR4J.Rd +++ b/man/Param_Sets_GR4J.Rd @@ -56,7 +56,7 @@ Param_Sets_GR4J <- as.matrix(Param_Sets_GR4J) InputsModel <- CreateInputsModel(FUN_MOD = RunModel_GR4J, DatesR = BasinObs$DatesR, Precip = BasinObs$P, PotEvap = BasinObs$E) -## ---- calibration step +## --- calibration step ## short calibration period selection (< 6 months) Ind_Cal <- seq(which(format(BasinObs$DatesR, format = "\%Y-\%m-\%d")=="1990-01-01"), @@ -82,7 +82,7 @@ OutputsCrit_Loop <- apply(Param_Sets_GR4J, 1, function(Param) { Param_Best <- unlist(Param_Sets_GR4J[which.max(OutputsCrit_Loop), ]) -## ---- validation step +## --- validation step ## validation period selection Ind_Val <- seq(which(format(BasinObs$DatesR, format = "\%Y-\%m-\%d")=="1990-03-01"), diff --git a/man/RunModel_CemaNeige.Rd b/man/RunModel_CemaNeige.Rd index 2fc511d5..685cb2a6 100644 --- a/man/RunModel_CemaNeige.Rd +++ b/man/RunModel_CemaNeige.Rd @@ -79,7 +79,7 @@ Ind_Run <- seq(which(format(BasinObs$DatesR, format = "\%Y-\%m-\%d")=="1990-01-0 which(format(BasinObs$DatesR, format = "\%Y-\%m-\%d")=="1999-12-31")) -## ---- original version of CemaNeige +## --- original version of CemaNeige ## preparation of the RunOptions object RunOptions <- CreateRunOptions(FUN_MOD = RunModel_CemaNeige, InputsModel = InputsModel, @@ -94,7 +94,7 @@ OutputsModel <- RunModel_CemaNeige(InputsModel = InputsModel, plot(OutputsModel) -## ---- version of CemaNeige with the Linear Hysteresis +## --- version of CemaNeige with the Linear Hysteresis ## preparation of the RunOptions object RunOptions <- CreateRunOptions(FUN_MOD = RunModel_CemaNeige, InputsModel = InputsModel, diff --git a/man/RunModel_CemaNeigeGR4H.Rd b/man/RunModel_CemaNeigeGR4H.Rd index 7dbe5222..d2a499da 100644 --- a/man/RunModel_CemaNeigeGR4H.Rd +++ b/man/RunModel_CemaNeigeGR4H.Rd @@ -108,7 +108,7 @@ Ind_Run <- seq(which(format(BasinObs$DatesR, format = "\%Y-\%m-\%d \%H:\%M")=="2 which(format(BasinObs$DatesR, format = "\%Y-\%m-\%d \%H:\%M")=="2008-12-31 23:00")) -## ---- original version of CemaNeige +## --- original version of CemaNeige ## preparation of the RunOptions object RunOptions <- CreateRunOptions(FUN_MOD = RunModel_CemaNeigeGR4H, InputsModel = InputsModel, diff --git a/man/RunModel_CemaNeigeGR4J.Rd b/man/RunModel_CemaNeigeGR4J.Rd index c451c6a3..9ab76645 100644 --- a/man/RunModel_CemaNeigeGR4J.Rd +++ b/man/RunModel_CemaNeigeGR4J.Rd @@ -104,7 +104,7 @@ Ind_Run <- seq(which(format(BasinObs$DatesR, format = "\%Y-\%m-\%d")=="1990-01-0 which(format(BasinObs$DatesR, format = "\%Y-\%m-\%d")=="1999-12-31")) -## ---- original version of CemaNeige +## --- original version of CemaNeige ## preparation of the RunOptions object RunOptions <- CreateRunOptions(FUN_MOD = RunModel_CemaNeigeGR4J, InputsModel = InputsModel, @@ -125,7 +125,7 @@ InputsCrit <- CreateInputsCrit(FUN_CRIT = ErrorCrit_NSE, InputsModel = InputsMo OutputsCrit <- ErrorCrit_NSE(InputsCrit = InputsCrit, OutputsModel = OutputsModel) -## ---- version of CemaNeige with the Linear Hysteresis +## --- version of CemaNeige with the Linear Hysteresis ## preparation of the RunOptions object RunOptions <- CreateRunOptions(FUN_MOD = RunModel_CemaNeigeGR4J, InputsModel = InputsModel, diff --git a/man/RunModel_CemaNeigeGR5H.Rd b/man/RunModel_CemaNeigeGR5H.Rd index 5b9f07e5..e7c3f8a9 100644 --- a/man/RunModel_CemaNeigeGR5H.Rd +++ b/man/RunModel_CemaNeigeGR5H.Rd @@ -109,7 +109,7 @@ Ind_Run <- seq(which(format(BasinObs$DatesR, format = "\%Y-\%m-\%d \%H:\%M")=="2 which(format(BasinObs$DatesR, format = "\%Y-\%m-\%d \%H:\%M")=="2008-12-31 23:00")) -## ---- original version of CemaNeige +## --- original version of CemaNeige ## Imax computation Imax <- Imax(InputsModel = InputsModel, IndPeriod_Run = Ind_Run, diff --git a/man/RunModel_CemaNeigeGR6J.Rd b/man/RunModel_CemaNeigeGR6J.Rd index 65e9635d..e9a37d4d 100644 --- a/man/RunModel_CemaNeigeGR6J.Rd +++ b/man/RunModel_CemaNeigeGR6J.Rd @@ -108,7 +108,7 @@ Ind_Run <- seq(which(format(BasinObs$DatesR, format = "\%Y-\%m-\%d")=="1990-01-0 which(format(BasinObs$DatesR, format = "\%Y-\%m-\%d")=="1999-12-31")) -## ---- original version of CemaNeige +## --- original version of CemaNeige ## preparation of the RunOptions object RunOptions <- CreateRunOptions(FUN_MOD = RunModel_CemaNeigeGR6J, InputsModel = InputsModel, @@ -129,7 +129,7 @@ InputsCrit <- CreateInputsCrit(FUN_CRIT = ErrorCrit_NSE, InputsModel = InputsMo OutputsCrit <- ErrorCrit_NSE(InputsCrit = InputsCrit, OutputsModel = OutputsModel) -## ---- version of CemaNeige with the Linear Hysteresis +## --- version of CemaNeige with the Linear Hysteresis ## preparation of the RunOptions object RunOptions <- CreateRunOptions(FUN_MOD = RunModel_CemaNeigeGR6J, InputsModel = InputsModel, diff --git a/man/TransfoParam.Rd b/man/TransfoParam.Rd index de58b74b..2029ed45 100644 --- a/man/TransfoParam.Rd +++ b/man/TransfoParam.Rd @@ -55,7 +55,7 @@ TransfoParam_CemaNeigeHyst(ParamIn, Direction) \examples{ library(airGR) -## ---- generic function +## --- generic function ## transformation Raw -> Transformed for the GR4J model Xraw <- matrix(c(+221.41, -3.63, +30.00, +1.37, @@ -72,7 +72,7 @@ Xtran <- matrix(c(+3.60, -2.00, +3.40, -9.10, Xraw <- TransfoParam(ParamIn = Xtran, Direction = "TR", FUN_TRANSFO = TransfoParam_GR4J) -## ---- specific function +## --- specific function ## transformation Raw -> Transformed for the GR4J model Xraw <- matrix(c(+221.41, -3.63, +30.00, +1.37, -- GitLab