Covariance matrix not positive semidefinite
Closed this issue · 1 comments
mgeisslinger commented
When I try to compute the explicit probabilities of the bivariate gaussian distribution, I first define the covariance matrix as [[1/sigX, rho], [rho, 1/sigY]]. This is working for most of the predictions. However, sometimes this matrix is not positive semidefinite which throws an error. Any clue on what am I doing wrong?
nachiket92 commented
sigX and sigY are the reciprocals of standard deviations along X and Y. Rho is the correlation of X and Y.
The covariance matrix will be: [[(1/sigX)^2, rho/(sigX.sigY)], [rho/(sigX.sigY), (1/sigY)^2]