Re: [R] Getting the numeric value of difftime

From: Gabor Grothendieck <ggrothendieck_at_gmail.com>
Date: Sat 14 Jan 2006 - 00:17:15 EST

This was just discussed two days ago:

https://www.stat.math.ethz.ch/pipermail/r-help/2006-January/084453.html

On 1/13/06, Christian Neumann <christian.neumann@ai.wu-wien.ac.at> wrote:
> Hi folks,
>
> I have a small, maybe newbie, question concerning date operations.
> The follwing snippet
>
> date1 = "2005-11-20";
> date2 = "2005-11-17";
> difftime(date1, date2)
>
> results in "Time difference of 3 days". How can I extract just the
> numerical value 3?
> As a workaround I apply mean() on the result which gives me just a
> numerical value.
>
> Thanks a lot,
>
> Christian
>
> ______________________________________________
> 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
>



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 Received on Sat Jan 14 00:49:28 2006

This archive was generated by hypermail 2.1.8 : Sat 14 Jan 2006 - 02:22:04 EST