Compute the Trace of a Matrix.

Description

Function computes the sum of main-diagonal elements of a square matrix.

Usage

1
Trace(x, quiet = FALSE)

Arguments

x

(matrix, Matrix) object

quiet

(logical) TRUE = will suppress any warning, which will be issued otherwise

Value

(numeric) value, the trace of the matrix

Want to suggest features or report bugs for rdrr.io? Use the GitHub issue tracker.