write.lars(file = "", dat, var, start, end)
# write observed climate data (*.sr)
write.lars(file = "", dat, var, start, end)# read synthetic (*.dat) or observed data (*.sr)
read.lars(file,
head=c("year","yday","t_max","t_min","precip","solar"),
year.offset=0)
# experimental functions (may not work great; or at all!)
lars2help(infile, outfile, year.offset, region)
write.lars.scenario(file, dat1, dat2, name="anomaly")
read.lars can read either
file="",data.frame of climate datadatdatc("MAX","MIN","RAIN","RAD")); if missing, will try and use
t_min, t_max, precip, and solar within
names(dat)integer starting year (assumed to be 1
of January), or a Date object of the exact dateinteger ending year (assumed to be 31 of
December), or a Date object of the exact datefile to be used for datfile and what is
needed in Rusing Datevar parameter. These
should be the same found in the station file, with Date object.
Data exported from write.lars always has legal (according to
the Gregorian calendar) and increasing sequence of days between
start and end (even if there are gaps in
dat). Missing data values are written as -99., as
specified in the LARS-WG manual, Version 4.0. lars2help and write.lars.scenario are experimental
functions to translate data between LARS and HELP (see
write.help for more info).
write.help, read.sdsm