TMS TMS - 4 months ago 13
R Question

Convert day of year to date

How do I convert day-of-year to date?

I.e. the opposite to: How do you convert POSIX date to day of year in R?


This is the way I do it:

as.Date(104, format = "%j", origin = "1.1.2014")
# "2014-04-15"

PS: for those who wonder if answering my own question is encouraged, please look here: