Skip to contents

Adjust the periods of the observation and simulation data so that they match.

Usage

fix_dates(runr_obj, obs_obj, trim_start = NULL, trim_end = NULL)

Arguments

runr_obj

SWATrunR object

obs_obj

Observation dataframe with two columns named "date" and "value"

trim_start

(optional) The starting date to trim the data times series. Default trim_start = NULL. Example: trim_start = "2010-01-01"

trim_end

(optional) The ending date to trim the data times series. Default trim_end = NULL. Example trim_end = "2015-01-01"

Value

list with two elements: "simulation" SWATrunR object and "observation" dataframe with the same dates period.

Examples

if (FALSE) {
my_obj <- fix_dates(runr_obj = sim_flow, obs_obj = obs_wq,
trim_start = "2010-01-01", trim_end = "2015-01-01")
}