Example wrapper functions to execute the GR4J model and obtain the performance of two objective functions (KGE2012 and KGEGarcia), in a calibration (GR4JExampleCal) or a verification period (GR4JExampleVer). Keep in mind that, within hydroMOPSO, the calibration or verification wrapper functions essentially have to be prepared by the user, with the objective functions that are convenient and the output variables that are necessary.
Thus, the functions presented here are only intended to work with examples from the documentation and serve as a guide to:
1) The general scheme of the calibration/verification wrapper functions
2) The assimilation of mandatory inputs
3) The assimilation of mandatory outputs
GR4JExampleCal(param.values,
Obs,
Objs.names,
var.names,
var.units,
full.period,
warmup.period,
cal.period,
InputsModel,
RunOptions,
area)GR4JExampleVer(param.values,
Obs,
Objs.names,
var.names,
var.units,
full.period,
warmup.period,
cal.period,
InputsModel,
RunOptions,
area)
(list)
The returned list contains two elements
(numeric)
Vector with the numerical values of the objectives (GoF1 and GoF2).
(list)
List with as many elements as time series of the output variables of the model (in this case only one output variable: streamflows).
(numeric)
Vector with parameter set of the model
This is a mandatory input for any wrapper function to work with hydroMOPSO, preserve name and class
(list)
List with time series of observations of the output variables
This is a mandatory input for any wrapper function to work with hydroMOPSO, preserve name and class
(character)
Vector with the names of the optimisation objectives
This is a mandatory input for any wrapper function to work with hydroMOPSO, preserve name and class
(character)
Vector with the names of the output variables
This is a mandatory input for any wrapper function to work with hydroMOPSO, preserve name and class
(character)
Vector with the units of measurement of the output variables
This is a mandatory input for any wrapper function to work with hydroMOPSO, preserve name and class
(Date)
Vector with the dates of the full period (warmup + calibration and/or verification)
This is a mandatory input for any wrapper function to work with hydroMOPSO, preserve name and class
(Date)
Vector with the dates of the warmup period
This is a mandatory input for any wrapper function to work with hydroMOPSO, preserve name and class
(Date)
Vector with the dates of the calibration period
This is a mandatory input for any wrapper function to work with hydroMOPSO, preserve name and class
(list)
GR4J inputs structured with the function airGR::CreateInputsModel
This input has been included only for the execution of the GR4J model in particular
(list)
GR4J run options specified with the function airGR::CreateRunOptions
This input has been included only for the execution of the GR4J model in particular
(numeric)
Area of the basin (sq-m), necessary to pass the outlet streamflow to m3/s (cms)
This input has been included only for the execution of the GR4J model in particular
Rodrigo Marinao Rivas ra.marinao.rivas@gmail.com, Mauricio Zambrano-Bigiarini, mzb.devel@gmail.com
hydroMOPSO