Checks whether a symmetric matrix is positive definite by verifying that all its eigenvalues exceed a given tolerance. Positive definiteness guarantees, among other properties, that the matrix is invertible and suitable for use as a covariance or correlation matrix.

is_positive_definite(M, tol = 1e-06)

Arguments

M

a square, symmetric numeric matrix

tol

tolerance (default 1e-6)

Value

a boolean