From: Jean-Bernard A. <jb...@ph...> - 2000-06-02 16:32:39
|
Hey again! Why is (arange(2, typecode=Complex) % 2).typecode() object and not complex? Jean-Bernard Python 1.5.1 (#1, Dec 17 1998, 20:58:15) [GCC 2.7.2.3] on linux2 Copyright 1991-1995 Stichting Mathematisch Centrum, Amsterdam Hello from .pythonrc.py >>> from Numeric import * >>> (arange(2, typecode=Complex) % 2).typecode() 'O' >>> arange(2, typecode=Complex) % 2 array([0j , (1+0j) ],'O') >>> arange(2) % 2 array([0, 1]) I have the same result python 1.5.2 and Numeric 11. |