Revision 04bbc417cf2927b827660bc07743429783569aec authored by HwB on 10 February 2013, 00:00:00 UTC, committed by Gabor Csardi on 10 February 2013, 00:00:00 UTC
1 parent 0e3ae6b
Raw File
diag.R
##
##  m t r a c e . R  Test suite
##

Diag <- pracma::Diag

all.equal(Diag(matrix(1:12,3,4),  1), c(4,8,12))
all.equal(Diag(matrix(1:12,3,4), -1), c(2,6))
identical(Diag(Diag(c(1,5,9)), 0), c(1,5,9))
back to top