[R] R: mean from list

Rajarshi Guha rxg218 at psu.edu
Mon Feb 13 01:07:01 CET 2006


On Sun, 2006-02-12 at 19:21 -0400, Kjetil Brinchmann Halvorsen wrote:
> statistical.model at googlemail.com wrote:
> > great!! thanks very much, mean(unlist(lapply(listdata, function(z) z$c)))
> 
> WHY unlist(lapply(...   when sapply(...
> is simpler?

Aah! Immediately after sending it I realized the simpler form :-/

-------------------------------------------------------------------
Rajarshi Guha <rxg218 at psu.edu> <http://jijo.cjb.net>
GPG Fingerprint: 0CCA 8EE2 2EEB 25E2 AB04 06F7 1BB9 E634 9B87 56EE
-------------------------------------------------------------------
Finally I am becoming stupider no more
- Paul Erdos' epitaph




More information about the R-help mailing list