[R] read.table
Philipp Pagel
p.pagel at wzw.tum.de
Tue Feb 22 12:25:53 CET 2011
> I am using read.table to read a plan 3 column CSV file . the file is getting
> read .
>
> But the first column has datetime in the csv file in the following format:
> 20110221.114041
>
> But this is being read as 20110221 only . the time portion (decimal is
> missing) in the data frame
My guess is that ist does get read correctly but you only see part of
the actual number because R will usually not print all available
digits. Example:
> a <- 20110221.114041
> a
[1] 20110221
> options("digits")
$digits
[1] 7
> format(a, digits=7)
[1] "20110221"
> format(a, digits=20)
[1] "20110221.114041"
cu
Philipp
--
Dr. Philipp Pagel
Lehrstuhl für Genomorientierte Bioinformatik
Technische Universität München
Wissenschaftszentrum Weihenstephan
Maximus-von-Imhof-Forum 3
85354 Freising, Germany
http://webclu.bio.wzw.tum.de/~pagel/
More information about the R-help
mailing list