[SciPy-user] object_arrtype addition error

Chris Fonnesbeck fonnesbeck at gmail.com
Mon Nov 28 20:06:31 CST 2005

Under scipy_core, I have a dictionary that contains what I thought
were floating point numbers, but are actually 'object_arrtype':

(Pdb) aic_quantiles
{2.5: 345.38217627260781,
 25: 346.73173987124062,
 50: 347.50728308413125,
 75: 349.61766516420937,
 97.5: 361.87424170229531}
(Pdb) type(aic_quantiles[50])
Out[3]: <type 'object_arrtype'>

When I try and add a scalar to any of these, I get a TypeError:

(Pdb) aic_quantiles[50] + 4
*** TypeError: unsupported operand type(s) for +: 'object_arrtype' and 'int'
(Pdb) aic_quantiles[50] + 4.
*** TypeError: unsupported operand type(s) for +: 'object_arrtype' and 'float'

Surely this is not intended behaviour? If so, I need some clarification.


Chris Fonnesbeck
Atlanta, GA

More information about the SciPy-user mailing list