[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

From |
Kaleb Michaud <kaleb@stanford.edu> |

To |
statalist@hsphsun2.harvard.edu |

Subject |
st: Problem with Cholesky matrix function? |

Date |
Sun, 23 Nov 2003 17:14:42 -0800 |

(It's been 5 hours so I'm sending this one again - strange list behavior?)

I'm trying to produce for a Monte Carlo task 100K random vectors in 10-D space with N(0,S) distribution where the covariance matrix S is defined by:

symmetric S[10,10]

r1 r2 r3 r4 r5 r6 r7 r8 r9 r10

c1 1

c2 2 2

c3 3 3 3

c4 4 4 4 4

c5 5 5 5 5 5

c6 6 6 6 6 6 6

c7 7 7 7 7 7 7 7

c8 8 8 8 8 8 8 8 8

c9 9 9 9 9 9 9 9 9 9

c10 10 10 10 10 10 10 10 10 10 10

The problem is this:

. matrix C = cholesky(S)

matrix not positive definite

r(506);

Now, I've searched the list archives, the web and am pretty sure S is positive definite. I discovered this problem using the -drawnorm- program (it passed of the internal tests as a covariance matrix until it reached the cholesky function).

Any ideas as to what I can do (assuming either my matrix isn't positive definite or this function isn't working right)?

Thanks!

Kaleb Michaud

Arthritis Research Center

*

* For searches and help try:

* http://www.stata.com/support/faqs/res/findit.html

* http://www.stata.com/support/statalist/faq

* http://www.ats.ucla.edu/stat/stata/

**Follow-Ups**:**Re: st: Problem with Cholesky matrix function?***From:*May Boggess <mboggess@stata.com>

- Prev by Date:
**st: Re: MVPROBIT** - Next by Date:
**st: Using -if- when running panel-corrected OLS pooled regressions** - Previous by thread:
**st: Suppressing Output in Estimation, Take 2** - Next by thread:
**Re: st: Problem with Cholesky matrix function?** - Index(es):

© Copyright 1996–2016 StataCorp LP | Terms of use | Privacy | Contact us | What's new | Site index |