[R] Different way of aggregating

skan juanpide at gmail.com
Thu Aug 19 14:09:00 CEST 2010



Phil Spector wrote:
> 
> 
> For chron objects:
> 
>   aggregate(thedata$value,list(hour=hours(thedata$date)),mean)
> 
> 


Ok, thanks, that's what I need. Now it seems so easy...

Could you tell me why we write... ?
 aggregate(thedata$value,list(hour=hours(thedata$date)),mean)
instead of just
 aggregate(thedata$value,hours(thedata$date),mean)

thanks

-- 
View this message in context: http://r.789695.n4.nabble.com/Different-way-of-aggregating-tp2330497p2331072.html
Sent from the R help mailing list archive at Nabble.com.



More information about the R-help mailing list