R/tr.R

Defines functions tr

Documented in tr

tr<-function(X)
{
  # Calculates the trace of p x p matrix X

  return(sum(diag(X)))
}
tpepler/theolib documentation built on Aug. 10, 2021, 9:53 a.m.