This is probably a very basic question but since I did not deal with dates and times in R, I didn't know how to solve it. The problem is when I open a new R session and run sys.time()
it gives me wrong time. I found a solution to that Sys.setenv(TZ="TURKEY")
and changed it. However, when I close R and open it again. It goes back to wrong result again. How do I make this permanent?
> Sys.time()
[1] "2022-04-01 11:16:37 GMT"
Warning messages:
1: In normalizePath(dirname(f)) : path[1]="NA": No such file or directory
2: In as.POSIXlt.POSIXct(x, tz) :
unknown timezone 'zone/tz/2022a.1.0/zoneinfo/Europe/Istanbul'
> Sys.setenv(TZ="TURKEY")
> Sys.time()
[1] "2022-04-01 14:17:39 EEST"