covmat.check {phylopairs} | R Documentation |
covmat.check
Description
Tets for validity of a covariance matrix based on four conditions: symmetry, diagonal dominance, positive definiteness, and positive variance.
Usage
covmat.check(mat)
Arguments
mat |
A putative covariance matrix. |
Details
A valid covariance matrix must be symmetric, diagonally dominant (largest values
in each row are on the diagonal), positive definite, and have positive variance.
covmat.check
takes a matrix as input and tests for these four conditions.
Value
A data.frame containing logical "TRUE" or "FALSE" for each condition.
Examples
# Load sample covariance matrix
data(sim.cov.pairs)
# Test for validity
covmat.check(sim.cov.pairs)
[Package phylopairs version 0.1.0 Index]