4
I need the R to tell me month before we are, that is, we are in "2018-05" and I need it to give me "2018-04".
So far my solution has been:
format(Sys.Date()-as.integer(format(Sys.Date(), "%d")),"%Y-%m")
I believe there should be a more "clean".