Samuel Dupree
2015-12-15 04:39:34 UTC
I'm running Python 2.7.11 from the Anaconda distribution (version 2.4.1)
on a MacBook Pro running Mac OS X version 10.11.2 (El Capitan)
I'm attempting to use numpy.ma.polyfit to perform a linear least square
fit on some data I have. I'm running NumPy version 1.10.1. I've observed
that in executing either numpy.polyfit or numpy.ma.polyfit I get the
following traceback:
/Users/user/anaconda/lib/python2.7/site-packages/numpy/lib/polynomial.py:594:
RankWarning: Polyfit may be poorly conditioned
warnings.warn(msg, RankWarning)
Traceback (most recent call last):
File "ComputeEnergy.py", line 132, in <module>
coeffs, covar = np.ma.polyfit( xfit, yfit, fit_degree,
rcond=rcondv, cov=True )
File
"/Users/user/anaconda/lib/python2.7/site-packages/numpy/ma/extras.py",
line 1951, in polyfit
return np.polyfit(x, y, deg, rcond, full, w, cov)
File
"/Users/user/anaconda/lib/python2.7/site-packages/numpy/lib/polynomial.py",
line 607, in polyfit
return c, Vbase * fac
ValueError: operands could not be broadcast together with shapes (6,6) (0,)
I've attached a stripped down version of the Python program I'm running.
Any suggestions?
Sam Dupree.
on a MacBook Pro running Mac OS X version 10.11.2 (El Capitan)
I'm attempting to use numpy.ma.polyfit to perform a linear least square
fit on some data I have. I'm running NumPy version 1.10.1. I've observed
that in executing either numpy.polyfit or numpy.ma.polyfit I get the
following traceback:
/Users/user/anaconda/lib/python2.7/site-packages/numpy/lib/polynomial.py:594:
RankWarning: Polyfit may be poorly conditioned
warnings.warn(msg, RankWarning)
Traceback (most recent call last):
File "ComputeEnergy.py", line 132, in <module>
coeffs, covar = np.ma.polyfit( xfit, yfit, fit_degree,
rcond=rcondv, cov=True )
File
"/Users/user/anaconda/lib/python2.7/site-packages/numpy/ma/extras.py",
line 1951, in polyfit
return np.polyfit(x, y, deg, rcond, full, w, cov)
File
"/Users/user/anaconda/lib/python2.7/site-packages/numpy/lib/polynomial.py",
line 607, in polyfit
return c, Vbase * fac
ValueError: operands could not be broadcast together with shapes (6,6) (0,)
I've attached a stripped down version of the Python program I'm running.
Any suggestions?
Sam Dupree.