Skip to content
Prev 170735 / 398502 Next

Efficient matrix computations

it would be a bit more helpful if we knew more info regarding these 
matrices, for instance is P diagonal, etc. In any case, you could have a 
look at

crossprod()
# and
tcorssprod()

and, for the determinant maybe

prod(eigen(mat, symmetric = TRUE, only.values = FALSE)$values)
# or
prod(diag(chol(mat)))^2

are a bit faster than det(), but I haven't tested it.

I hope it helps.

Best,
Dimitris
Shimrit Abraham wrote: