[Scipy-svn] r6542 - trunk/scipy/optimize

scipy-svn@scip... scipy-svn@scip...
Fri Jun 18 14:39:19 CDT 2010


Author: rgommers
Date: 2010-06-18 14:39:18 -0500 (Fri, 18 Jun 2010)
New Revision: 6542

Modified:
   trunk/scipy/optimize/minpack.py
Log:
BUG: leastsq returned a scalar instead of array for single fit param. Fixes #1204.

Modified: trunk/scipy/optimize/minpack.py
===================================================================
--- trunk/scipy/optimize/minpack.py	2010-06-18 15:36:37 UTC (rev 6541)
+++ trunk/scipy/optimize/minpack.py	2010-06-18 19:39:18 UTC (rev 6542)
@@ -308,9 +308,6 @@
             except KeyError:
                 raise errors['unknown'][1](errors['unknown'][0])
 
-    if n == 1:
-        retval = (retval[0][0],) + retval[1:]
-
     mesg = errors[info][0]
     if full_output:
         cov_x = None



More information about the Scipy-svn mailing list