Francesc Altet wrote: >Hi, > >Is there any reason why the next works for some types: > >In [26]: numpy.int32() >Out[26]: 0 > >In [27]: numpy.float64() >Out[27]: 0.0 > >but don't for the next others? > >In [28]: numpy.int16() >--------------------------------------------------------------------------- ><type 'exceptions.TypeError'> Traceback (most recent call last) > >/home/faltet/python.nobackup/numpy/<ipython console> in <module>() > ><type 'exceptions.TypeError'>: function takes exactly 1 argument (0 given) > > >
I suppose because int() and float() work. I really didn't know that. If that is the case, then we should have all the scalar objects return default values. Please file a ticket. -Travis ------------------------------------------------------------------------- Take Surveys. Earn Cash. Influence the Future of IT Join SourceForge.net's Techsay panel and you'll get the chance to share your opinions on IT & business topics through brief surveys -- and earn cash http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV _______________________________________________ Numpy-discussion mailing list Numpy-discussion@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/numpy-discussion