Re: [R] as.date - german date format

From: Konga <ericwill75_at_yahoo.de>
Date: Wed, 9 Jan 2008 07:36:59 -0800 (PST)

Uwe Ligges-3 wrote:
>
>
>
> Konga wrote:

>> Hi,
>> 
>> I have a data.frame with the following variable:
>> $  xx  :Factor w/ 66 levels "01.02.2006","01.03.2006",..: 3 3 3 3 3 3 3 3
>> 3
>> 
>> now I´d like use "as.date" on it - if I comprehend the instructions on
>> http://finzi.psych.upenn.edu/R/library/base/html/format.Date.html
>> it should work like this:
>> 
>> as.date(xx, "%d.%m.%Y") - but it doesn´t...

>
> What is the error message?
> - Fehler in as.date(mydata$xx, "%d.%m.%Y") :
> Cannot coerce to date format
>
> Which R version is this?
> -2.6.0
>
> What are all the
> labels (in order to reproduce your error)?
> - The data.frame has 1500 objects - do you want me to print them all? Even
> the 66 different levels of the factor would be a little bit much, I think.
> But I printed them once, they all have the same format.
>
>
>
>
>
>
> in order to get better help.
>
> Uwe Ligges
>
>
>
>> the survival Package ist loaded - is there a problem with the german
>> format?
>> Or did I understand something wrong?
>> 
>> Much better than tranforming the format from to data would be to import
>> it
>> in the right format.
>> Is there a parameter for read.csv to get it as a date from the beginning?
>> 
>> 
>> 
>>

>
> ______________________________________________
> R-help@r-project.org mailing list
> 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.
>
>
-- 
View this message in context: http://www.nabble.com/as.date---german-date-format-tp14712654p14714199.html
Sent from the R help mailing list archive at Nabble.com.

______________________________________________
R-help_at_r-project.org mailing list
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.
Received on Wed 09 Jan 2008 - 15:40:29 GMT

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.2.0, at Wed 09 Jan 2008 - 18:30:05 GMT.

Mailing list information is available at https://stat.ethz.ch/mailman/listinfo/r-help. Please read the posting guide before posting to the list.

list of date sections of archive