[R] A Date related problem

Megh megh700004 at yahoo.com
Tue Dec 15 20:39:25 CET 2009


Dear all,

Please consider following date "as.Date("2009-02-01")". If I subtract "1"
then it will give last day, similarly if I subtract "2" it will give 2nd
last day. But what about if I want to get "last month", "2md last month"
i.e. "2009-01-01" or "2008-12-01" etc or even year?

Is there any automated way (like day-case, as explained) for doing that?

Your help will be highly appreciated.

Thanks,
-- 
View this message in context: http://n4.nabble.com/A-Date-related-problem-tp964584p964584.html
Sent from the R help mailing list archive at Nabble.com.




More information about the R-help mailing list