[SciPy-user] AttributeError: keys
Pearu Peterson
pearu at scipy.org
Fri May 21 06:17:38 EDT 2004
On Fri, 21 May 2004, Nils Wagner wrote:
> Python 2.3.3 (#1, Apr 6 2004, 01:47:39)
> [GCC 3.3.3 (SuSE Linux)] on linux2
> Type "help", "copyright", "credits" or "license" for more information.
> >>> from scipy import *
> >>> import IPython
> >>> a = zeros((2,2),Float)
> >>> a
> array([[ 0., 0.],
> [ 0., 0.]])
> >>> who (a)
> Traceback (most recent call last):
> File "<stdin>", line 1, in ?
> File "/usr/lib/python2.3/site-packages/scipy/common.py", line 253, in who
> for name in vardict.keys():
> AttributeError: keys
Read help(who). So try
who()
who({'a',a})
who(a) could never work in Python as it does in Matlab (who('a')).
However, who(a=a) could.
Regards,
Pearu
More information about the SciPy-User
mailing list