Robert Kern-2 wrote:
>
> Don't try to fit a Gaussian to a histogram using least-squares. It's an
> awful
> way to estimate the parameters. Just use np.mean() and np.cov() to
> estimate the
> mean and covariance matrix directly.
>
Ok, what about distributions other than gaussian? Would you us
I want to fit an n-dimensional distribution with an n-dimensional gaussian.
So far i have managed to do this in 2d (see below). I am not sure how to
convert this to work in n-dimensions. Using "ravel" on the arrays is not
ideal, but optimize does not appear to work on multidimensional arrays. It
s