[Numpy-discussion] Ticket #1223...
Tue Jun 29 22:16:30 CDT 2010
On Tue, Jun 29, 2010 at 6:03 PM, David Goldsmith
> On Tue, Jun 29, 2010 at 3:56 PM, <firstname.lastname@example.org> wrote:
>> On Tue, Jun 29, 2010 at 6:37 PM, David Goldsmith
>> <email@example.com> wrote:
>> > ...concerns the behavior of numpy.random.multivariate_normal; if that's
>> > of
>> > interest to you, I urge you to take a look at the comments (esp. mine
>> > :-) );
>> > otherwise, please ignore the noise. Thanks!
>> You should add the link to the ticket, so it's faster for everyone to
>> check what you are talking about.
> Ooops! Yes I should; here it is:
> Sorry, and thanks, Josef.
> NumPy-Discussion mailing list
As I recall, there is no requirement for the variance/covariance of
the normal distribution to be positive definite.
"The covariance matrix is allowed to be singular (in which case the
corresponding distribution has no density)."
So you must be able to draw random numbers from such a distribution.
Obviously what those numbers really mean is another matter (I presume
the dependent variables should be a linear function of the independent
variables) but the user *must* know since they entered it. Since the
function works the docstring Notes comment must be wrong.
Imposing any restriction means that this is no longer a multivariate
normal random number generator. If anything, you can only raise a
warning about possible non-positive definiteness but even that will
vary depending how it is measured and on the precision being used.
More information about the NumPy-Discussion