Is this what you want:

> x <- "date,value
+ 2006-5-5,1
+ 2006-5-10,2
+ 2006-5-20,3
+ 2006-5-30,4"
> y <- textConnection(x)
> z <- read.csv(y, colClasses=c("POSIXct", 'integer'))
>
> z
        date value
1 2006-05-05     1
2 2006-05-10     2
3 2006-05-20     3
4 2006-05-30     4



On 6/21/06, Kerpel, John <John.Kerpel@infores.com> wrote:
>
> Hi Folks!
>
>
>
> I'm reading in some data from a .csv file that has a date column.
>
>
>
> How do I use colClasses to get read.csv to recognize the date column?
> The documentation on this seems to be nil -
>
> And yes, I've read help and R Data Import/Export and can't figure out
> what the colClasses syntax is.
>
>
>
> Thanks,
>
>
>
> john
>
>
>        [[alternative HTML version deleted]]
>
> ______________________________________________
> R-help@stat.math.ethz.ch mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide!
> http://www.R-project.org/posting-guide.html
>



-- 
Jim Holtman
Cincinnati, OH
+1 513 646 9390 (Cell)
+1 513 247 0281 (Home)

What is the problem you are trying to solve?

	[[alternative HTML version deleted]]

