Computes the date corresponding to a given day number (or vector of) with reference to a start year. Typically, the start year should be the year of a STICS simulation start, but not necessarily.

compute_date_from_day(day, start_year)

Arguments

day

day number(s) to be converted

start_year

year to be used as time reference (simulation start year).

Value

Date vector

Author

Timothee Flutre

Examples


compute_date_from_day(day = 290, start_year = 1994)
#> [1] "1994-10-17"

compute_date_from_day(day = 700, start_year = 1994)
#> [1] "1995-12-01"