[R] Determinant and inverse using cholsky parameter
nataraj at orchidpharma.com
nataraj at orchidpharma.com
Mon Jun 11 08:55:38 CEST 2012
Thanks for all who replied me to this topic. I have the "L" (cholesky decomposed matrix)as a vector listed as columwise as mentioned in the article http://citeseerx.ist.psu.edu/viewdoc/summary?doi=10.1.1.31.494 and looking for functions to convert the vector into inverse matrix ( but chol2inv mentioned by Kjetil, takes up matrix form) and the corresponding determinant value (square of the product of the diagonal element of the L).
I am going to use the function in an maximum likelihood optimization routine for estimating variables in a variance-covariance matrix.
Thanks and regards,
B.Nataraj
-----Original Message-----
From: r-help-bounces at r-project.org [mailto:r-help-bounces at r-project.org] On Behalf Of Özgür Asar
Sent: Friday, June 08, 2012 7:38 PM
To: r-help at r-project.org
Subject: Re: [R] Determinant and inverse using cholsky parameter
Hi,
Isn't the Cholesky decomposition of A=L (L)^T where T stands for "transpose"
and L is the Cholesky factor of A.
You say you have the Cholesky decomposition, isn't it L (above)?
A<-L%*%t(L)
det(A)
solve(A)
would be your answer.
Hope this helps
Ozgur
--
View this message in context: http://r.789695.n4.nabble.com/Determinant-and-inverse-using-cholsky-parameter-tp4632769p4632808.html
Sent from the R help mailing list archive at Nabble.com.
______________________________________________
R-help at r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.
More information about the R-help
mailing list