Skip to contents

Subset each SIPNET input file and write a new file containing values >= start.time and < end.time (note: end time is not inclusive)

Usage

split_inputs.SIPNET(
  start.time,
  stop.time,
  inputs,
  overwrite = FALSE,
  outpath = NULL
)

Arguments

start.time

Start date or datetime for splitting

stop.time

End date or datetime for splitting

inputs

Named inputs list as provided by PEcAn settings. Must have structure like: list(met = list(path = "path/to/sipnet.clim"), events = list(path = "path/to/events.in"), ...)

overwrite

if TRUE, overwrite existing target file (Default FALSE)

outpath

if specified, write output to a new directory. Default NULL writes back to the directory being read

Value

Modified inputs list with all path entries replaced with new paths (suitable for inserting back into settings$run$inputs).

Details

NOTE that sipnet met files contain dates and times, while sipnet event files contain only dates. Comparing a datetime to a date will coerce the date to midnight UTC.

Author

Alexey Shiklomanov