Folks,
is there a collection of gotchas where Numpy differs from python, points that have puzzled and cost time ?
"The horror of that moment I shall never never forget !"
"You will, though," the Queen said, "if you don't make a memorandum of it."
For example, NaNs are always trouble, anywhere. If you can explain this without running it, give yourself a point --
from numpy import array, NaN, isnan
pynan = float("nan")
print pynan is pynan, pynan is NaN, NaN is NaN
a = (0, pynan)
print a, a[1] is pynan, any([aa is pynan for aa in a])
a = array(( 0, NaN ))
print a, a[1] is NaN, isnan( a[1] )
(I'm not knocking numpy, lots of good work there, just think a FAQ or Wiki of gotchas would be useful.)
Edit: I was hoping to collect half a dozen gotchas (surprises for people learning Numpy).
Then, if there are common gotchas or, better, common explanations,
we could talk about adding them to a community Wiki (where ?)
It doesn't look like we have enough so far.