empca icon indicating copy to clipboard operation
empca copied to clipboard

warning when using weights

Open londumas opened this issue 6 years ago • 0 comments

I get the following warning when using weights, I bet it can simply be corrected:

<me>/Programs/sbailey/empca/empca.py:256: FutureWarning: `rcond` parameter will change to the default of machine precision times ``max(M, N)`` where M and N are the input matrix dimensions.
To use the future default and silence this warning we advise to pass `rcond=None`, to keep using the old, explicitly pass `rcond=-1`.
  x = np.linalg.lstsq(A, b)[0]

Here is a minimal example of code:

import scipy as sp
import empca

flux = sp.loadtxt('exemple_flux.txt')
weights = sp.loadtxt('exemple_weight.txt')
model = empca.empca(flux, niter=1, nvec=1, weights=weights)

exemple_flux.txt exemple_weight.txt

londumas avatar Mar 09 '19 06:03 londumas