drawing bivariate gaussian distributions in matplotlib

red picture red · Mar 2, 2012 · Viewed 13.2k times · Source

How can we plot (in python matplotlib) bivariate Gaussian Distributions , given their centers and covariance matrices as numpy arrays?

Let's say that our parameters are as follows:

center1=np.array([3,3])
center2=np.array([5,5])
cov1=np.array([ [1.,.5], [.5,.1]])
cov2=np.array([ [.2,.5], [.5,.2]])

Answer

ev-br picture ev-br · Mar 2, 2012