[Numpy-discussion] Re: [SciPy-user] [numarray issue] nonzero? Comments on new name solicited

Pearu Peterson pearu at cens.ioc.ee
Mon May 5 13:27:07 EDT 2003


On Mon, 5 May 2003, Perry Greenfield wrote:

> Any objections to using "at"? Any better suggestions.

For me 'wheretrue' sounds most accurate but I agree, it's longish.

Its short form 'where' is less accurate (because of its general
meaning) but not too confusing.

At first, 'at' confused me a little... until I figured out its long
version 'trueat'.

Hmm, I have always assumed that 'nonzero(x)' means elementwise 
'not not x' (like Python __nonzero__ is equivalent to 'not not') and
therefore never felt the need to use it.
But now I see I was wrong! So, 'nonzero' sounded and still 
sounds misleading for me.

For 'nz' I am -1 because 'nz' can often be a suitable variable name.

In summary, I would like 'trueat' the most and 'nonzero' the least.
'where' and 'at' (in that order) are somewhere in between.

Pearu





More information about the NumPy-Discussion mailing list