Skip to content
Prev 368154 / 398500 Next

Date operation Question in R

But since the original one asked for a starting point of Sys.Date, on this 31st day of March, it might be useful to demonstrate that there are pifalls for the uninitiated useR. Note the many duplicate "months":
[1] "Jan-2017" "Mar-2017" "Mar-2017" "May-2017" "May-2017" "Jul-2017" "Jul-2017"
 [8] "Aug-2017" "Oct-2017" "Oct-2017" "Dec-2017" "Dec-2017" "Jan-2018" "Mar-2018"
[15] "Mar-2018" "May-2018" "May-2018" "Jul-2018" "Jul-2018" "Aug-2018" "Oct-2018"
[22] "Oct-2018" "Dec-2018" "Dec-2018"