det
and determinant
calculate the determinant of a
positive definite sparse matrix. determinant
returns separately the
modulus of the determinant, optionally on the logarithm scale, and
the sign of the determinant.# det(x, ...)
determinant(x, logarithm = TRUE, ...)
spam
or a Cholesky factor of
class spam.chol.NgPeyton
.TRUE
(default) return the logarithm of the
modulus of the determinant.method
argument
and additional parameters used by the method.det
, the determinant of x
. For determinant
, a list with
componentslogarithm
is FALSE
; otherwise the
logarithm of the modulus.NA
. The determinant is based on the product of the diagonal entries of a
Cholesky factor, i.e. internally, a Cholesky decomposition is
performed. By default, the NgPeyton algorithm with minimal degree
ordering us used. To change the methods or supply additonal parameters
to the Cholesky factorization function, see the help for chol
.
The determinant of a Cholesky factor is also defined.
chol
x <- spam( c(4,3,0,3,5,1,0,1,4),3)
det( x)
determinant( x)
det( chol( x))
Run the code above in your browser using DataLab