[SciPy-user] float96 displayed (incorrectly) as float64

Leo Trottier trottier+pylist@gmail....
Wed Feb 18 12:42:08 CST 2009


Hi,

I'd like to show off how much easier it is to work with multiple data types
in numpy (as compared with matlab).  It would be especially handy to show
off float96 , etc.

Unfortunately, this doesn't seem to work under Vista or Windows XP:


###########################
Python 2.5.4 (r254:67916, Dec 23 2008, 15:10:54) [MSC v.1310 32 bit (Intel)]
Type "copyright", "credits" or "license" for more information.

IPython 0.9.1 -- An enhanced Interactive Python.
...
IPython profile: xy
# NOTE: numpy.__version__ == '1.2.1'
#  ... and: scipy.__version__ == '0.7.0'

In [1]: a = array(1.0,dtype=float96)

In [2]: print a # DISPLAYS INCORRECTLY
0.0

In [3]: print a.astype(float64) # DISPLAYS CORRECTLY -- DATA STILL THERE
1.0

In [4]: print (a*-1).astype(float64) # MULTIPLICATION APPEARS TO WORK
PROPERLY
-1.0
#############################

Does anyone know of a work-around?

Leo
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://projects.scipy.org/pipermail/scipy-user/attachments/20090218/675753f9/attachment.html 


More information about the SciPy-user mailing list