[R] Cholesky decomposition error

Rui Barradas ruipbarradas at sapo.pt
Thu Jun 14 16:27:49 CEST 2012


Hello,
Hello,

If the input matrix is symmetric, positive definite then the Cholesky 
decomposition algorithm is stable. That's why it is so used in 
statistics, where many times the matrices meet those conditions.

Therefore, the matrix isn't symmetric, positive definite to begin with.

Rui Barradas

Em 14-06-2012 13:48, Bert Gunter escreveu:
> Your matrix is not symmetric, positive definite. If you don't know
> what this means, you shouldn't be using chol()
>
> This may be because it isn't to begin with, or due to numerical error,
> it doesn't behave as one in the decomposition. My relative ignorance
> of numeric methods for linear algebra prevents me from saying more
> than that.
>
> -- Bert
>
> On Thu, Jun 14, 2012 at 4:23 AM,  <nataraj at orchidpharma.com> wrote:
>> Dear friends,
>>
>> When I do Cholesky decomposition for a 15x15 matrix using the function chol(), I get the following error for which I do not understand the meaning of the error
>>
>> Error in chol.default(M_cov) :
>>   the leading minor of order 10 is not positive definite
>>
>> When I searched online for similar error reported earlier I could get few hits but not of much help to resolve my error and one post suggested to use different function called sechol() from accuracy package but that did not work and it leads to different errors. So I want to stick to function chol() itself.
>>
>> Could you please help me to find where things are going wrong in my matrix?
>>
>>
>> Thanks and regards,
>> B.Natarj
>>
>> ______________________________________________
>> 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