powered by
Checks if a matrix is Compound Symmetric.
is.CompSym(mat, tol = 1e-05)
True if the matrix is compound symmetric.
The matrix to be tested.
a number indicating the smallest acceptable difference between off diagonal values.
gcmat <- matrix(c(1,0.2,0.1,0.2,1,0.3,0.1,0.3,1), nrow = 3) csmat <- matrix(c(1,0.2,0.2,0.2,1,0.2,0.2,0.2,1), nrow = 3) is.CompSym(csmat)
Run the code above in your browser using DataLab