tr: Trace of A Matrix

Description Usage Arguments Value See Also Examples

Description

This function calculates the trace of a given numeric square matrix. This function should not be called directly in this package. It is called by other functions like dscore and sscore.

Usage

1
tr(X)

Arguments

X

A square matrix

Value

A numeric value which is the sum of the values on the diagnonal.

See Also

dscore, sscore

Examples

1
2
	A=matrix(seq(1:9),nrow=3,ncol=3)
	tr(A)

KMDA documentation built on May 2, 2019, 3:59 p.m.