Skip to content
Prev 199939 / 398502 Next

as.Date from data.frame

On Nov 11, 2009, at 12:06 PM, separent wrote:

            
In a data frame, you cannot change the data type for a row, without  
changing the data type for the entire column.

That being said, it looks to me like each column contains continuous  
data for a chronological series.

If that is correct, then you want the dates to be the column names and  
not the first row., Thus, when you used read.table(), you should have  
included the argument 'header = TRUE', which would do just that. With  
read.table(), header is FALSE by default.

HTH,

Marc Schwartz