Hi Phil,
Well thank you very much for this detailed explanation. It will help
me when summarizing information over periods of time using either
summarize (Hmisc) or summaryBy (doBy). Until now, doing so resulted in
"mean" time for each "group" being transformed as a number of seconds,
as
Stavros Macrakis wrote:
> I have documented some of these issues in my email "Semantics of
> sequences in R" (22/02/2009 3:42 PM) and other emails, and I have
> proposed to write code to resolve them, but have not received a warm
> reception.
>
you said 'it *is* a mess', didn't you? warm re
Stavros Macrakis wrote:
> It does seem sensible that median and quantile would work for the
> POSIXct, Date, and other classes for which they are logically
> well-defined, but strangely enough, they do not (except for odd-length
> input). The summary function has a special case (summary.POSIXct)
>
It does seem sensible that median and quantile would work for the
POSIXct, Date, and other classes for which they are logically
well-defined, but strangely enough, they do not (except for odd-length
input). The summary function has a special case (summary.POSIXct)
which does the straightforward, o
illiam Dunlap
> Sent: Tuesday, March 10, 2009 11:37 AM
> To: 'r-help@r-project.org'
> Subject: Re: [R] puzzled by math on date-time objects
>
> Your problem arises in R 2.8.1 (and 2.9.0-devel, but not 2.7.0) when
> length(POSIXct object) is even, because median(POSIXct ob
ystem i686, linux-gnu
status
major 2
minor 8.1
year 2008
month 12
day22
svn rev47281
language R
version.string R version 2.8.1 (2008-12-22)
Bill Dunlap
TIBCO Software Inc - Spotfire Division
wdunlap tibco.com
--------
Hi,
I don't understand the following. When I create a small artificial set
of date information in class POSIXct, I can calculate the mean and the
median:
a = as.POSIXct(Sys.time())
a = a + 60*0:10; a
[1] "2009-03-10 11:30:16 EDT" "2009-03-10 11:31:16 EDT" "2009-03-10
11:32:16 EDT"
[4]
7 matches
Mail list logo