Skip to content
Prev 87378 / 398502 Next

subsetting a list of matrices

Hi All,

I have a list of matrices:
[,1] [,2]
[1,]    1    4
[2,]    2    5
[3,]    3    6
[,1] [,2] [,3] [,4] [,5] [,6]
[1,]   18   21   24   27   30   33
[2,]   19   22   25   28   31   34
[3,]   20   23   26   29   32   35
I want to create a second list that is has a subset each matrix in the
list subsetting so I get the 2nd and 3rd row of each (and all columns).

How could I do that (apart from looping)?

Regards,

Federico Calboli