maxone2 {adana} | R Documentation |
Calculates the sum of each row of a matrix or data frame.
maxone2(x, ...)
x |
A matrix or a data frame |
... |
Further arguments passed to or from other methods. |
A vector includes sum of each row in a matrix or data frame
Zeynel Cebeci & Erkut Tekeli
binmat = matrix(nrow=5, ncol=8, byrow=TRUE, c(
1, 0, 1, 0, 1, 1, 1, 0,
1, 1, 1, 0, 1, 0, 0, 0,
1, 1, 1, 1, 1, 1, 1, 1,
0, 1, 0, 1, 0, 1, 1, 1,
0, 0, 0, 0, 0, 0, 0, 0
))
rownames(binmat) = paste0("C",1:5)
maxone2(binmat)