If you just want a list of matrices and their counts, you can use
Peter's list of matrices, L, and then:
With plyr:
require(plyr)
count(unlist(lapply(L, toString)))
Without plyr:
as.data.frame(table(unlist(lapply(L, toString
Cheers,
Jeff.
On Sat, Oct 9, 2010 at 12:44 PM, Peter Ehlers wr
On 2010-10-07 10:10, Jim Silverton wrote:
Hello,
I gave a list of 2 x 2 matrices called matlist. I have about 5000 2 x 2
matrices. I would like to count how many of each 2 x 2 unique matrix I have.
So I am thinking that I need a list of the unique 2 x 2 matrices and their
counts. Can anyone help
I may or may not have the most elegant solution to this problem, but if it
were me, I would probably put them all in a list and then
unique_matrix_list <- unique(list_of_matrix)
# number of unique matricies:
length(unique_matrix_list)
# count the number of each matrix,
for (m in unique_ma
Hello,
I gave a list of 2 x 2 matrices called matlist. I have about 5000 2 x 2
matrices. I would like to count how many of each 2 x 2 unique matrix I have.
So I am thinking that I need a list of the unique 2 x 2 matrices and their
counts. Can anyone help.
--
Thanks,
Jim.
[[alternative H
4 matches
Mail list logo