hi James, I think you have to have a starting date ("origin") for as.Date to convert numbers to dates.
Jim On Sun, Nov 6, 2016 at 12:10 PM, James Hirschorn <james.hirsch...@hotmail.com> wrote: > This seemed odd so I wanted to check: > > > x <- foreach(i=10000:10100, .combine='c') %do% { as.Date(i) } > > yields a numeric vector for x: > > > class(x) > [1] "numeric" > > Should it not be a vector of Date? > > ______________________________________________ > R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see > https://stat.ethz.ch/mailman/listinfo/r-help > PLEASE do read the posting guide http://www.R-project.org/posting-guide.html > and provide commented, minimal, self-contained, reproducible code. ______________________________________________ R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.