[R] formatting date strings
Prof Brian Ripley
ripley at stats.ox.ac.uk
Wed Feb 13 10:50:06 CET 2002
On Wed, 13 Feb 2002, Jason Turner wrote:
> On Wed, Feb 13, 2002 at 03:47:01PM +1100, Jeremy.Whish at csiro.au wrote:
> ...
> > I have a simulation model that out puts dates in a standard dd/mm/yy format
> > R reads this as a factor
>
> Step 1 - you need to read it as plain dumb text first.
> In help(read.table), check out the "as.is" option. You probably want
> as.is=TRUE
Please check out argument colClasses. You want colClasses = "character'
for that column.
as.is is very confusing: it was for a long time incorrectly documented
which did not reduce the confusion. I would like to deprecate it.
--
Brian D. Ripley, ripley at stats.ox.ac.uk
Professor of Applied Statistics, http://www.stats.ox.ac.uk/~ripley/
University of Oxford, Tel: +44 1865 272861 (self)
1 South Parks Road, +44 1865 272860 (secr)
Oxford OX1 3TG, UK Fax: +44 1865 272595
-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !) To: r-help-request at stat.math.ethz.ch
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._
More information about the R-help
mailing list