Re: [Numpy-discussion] corrcoef of masked array

2007-06-04 Thread Jesper Larsen
On Wednesday 30 May 2007 19:48, Robert Kern wrote: > I'm afraid this doesn't work, either. Correlation matrices are constrained > to be positive semidefinite; that is, all of their eigenvalues must be >= > 0. Calculating each of the correlation coefficients in a pairwise fashion > doesn't incorpora

Re: [Numpy-discussion] corrcoef of masked array

2007-05-30 Thread Robert Kern
Jesper Larsen wrote: > Here is my solution for calculating the correlation coefficients for masked > arrays. Comments are appreciated: > > def macorrcoef(data1, data2): > """ > Calculates correlation coefficients taking masked out values > into account. > > It is assumed (but not checke

Re: [Numpy-discussion] corrcoef of masked array

2007-05-30 Thread Jesper Larsen
On Friday 25 May 2007 19:18, Robert Kern wrote: > Jesper Larsen wrote: > > Hi numpy users, > > > > I have a masked array of dimension (nvariables, nobservations) that > > contain missing values at arbitrary points. Is it safe to rely on > > numpy.corrcoeff to calculate the correlation coefficients

Re: [Numpy-discussion] corrcoef of masked array

2007-05-26 Thread Stefan van der Walt
Hi Jesper On Fri, May 25, 2007 at 10:37:44AM +0200, Jesper Larsen wrote: > I have a masked array of dimension (nvariables, nobservations) that contain > missing values at arbitrary points. Is it safe to rely on numpy.corrcoeff to > calculate the correlation coefficients of a masked array (it see

Re: [Numpy-discussion] corrcoef of masked array

2007-05-25 Thread Robert Kern
Jesper Larsen wrote: > Hi numpy users, > > I have a masked array of dimension (nvariables, nobservations) that contain > missing values at arbitrary points. Is it safe to rely on numpy.corrcoeff to > calculate the correlation coefficients of a masked array (it seems to give > reasonable results

[Numpy-discussion] corrcoef of masked array

2007-05-25 Thread Jesper Larsen
Hi numpy users, I have a masked array of dimension (nvariables, nobservations) that contain missing values at arbitrary points. Is it safe to rely on numpy.corrcoeff to calculate the correlation coefficients of a masked array (it seems to give reasonable results)? Cheers, Jesper __