Skip to content
Prev 180931 / 398506 Next

how to calculate means of matrix elements

In that case use a modification of Jim's solution:

a <- array(cbind(mat1, mat2, mat3), c(3, 3, 3))
apply(a, 1:2, mean, na.rm = TRUE)
On Tue, May 19, 2009 at 8:49 AM, dxc13 <dxc13 at health.state.ny.us> wrote: