Windows, IDLE, __doc_, other

W. eWatson wolftracks at invalid.com
Sun Dec 20 21:16:52 EST 2009


When I use numpy.__doc__ in IDLE under Win XP, I get a heap of words 
without reasonable line breaks.

"\nNumPy\n=====\n\nProvides\n  1. An array object of arbitrary 
homogeneous items\n  2. Fast mathematical operations over arrays\n  3. 
Linear Algebra, Fourier Transforms, Random Number
...

Is there a way to get this formated properly.

If I use dir(numpy), I get yet a very long list that starts as:
['ALLOW_THREADS', 'BUFSIZE', 'CLIP', 'DataSource', 'ERR_CALL', 
'ERR_DEFAULT', 'ERR_DEFAULT2', 'ERR_IGNORE', 'ERR_LOG', 'ERR_PRINT', 
'ERR_RAISE', 'ERR_WARN', 'FLOATING_POINT_SUPPORT', 'FPE_DIVIDEBYZERO', 
'FPE_INVALID', 'FPE_OVERFLOW', 'FPE_UNDERFLOW', 'False_', 'Inf', 
'Infinity', 'MAXDIMS', 'MachAr', 'NAN', 'NINF', 'NZERO', 'NaN', 'PINF', 
'PZERO', 'PackageLoader', 'RAISE', 'RankWarning', 'SHIFT_DIVIDEBYZERO', 
'SHIFT_INVALID', 'SHIFT_OVERFLOW', 'SHIFT_UNDERFLOW', 'ScalarType', 
'Tester', 'True_', 'UFUNC_BUFSIZE_DEFAULT'
...
I see this might be a dictionary. What can I do to make it more readable 
or useful, or is that it? Is there a more abc as in Linux?

It the IDLE shell, it's not possible to retrieve lines entered earlier 
without copying them. Is there an edit facility?



More information about the Python-list mailing list