Skip to content
Prev 165703 / 398502 Next

Componentwise means of a list of matrices?

Hi Marc,

thanks, that works great! With yet another apply(), I can also make it 
accept psych::winsor() and trimming:

some.sort.of.apply <- function ( foo, FUN, ... ) {
   matrix(apply(sapply(foo, c),1,FUN,...), dim(foo[[1]]))
}
some.sort.of.apply ( foo, FUN=winsor,trim=0.3 )

Thank you all for your help!
Stephan


Marc Schwartz schrieb: