[Numpy-discussion] Don't like the short names like lstsq and irefft

Sasha ndarray at mac.com
Thu Jun 15 09:16:56 EDT 2006


On 6/15/06, Paul Dubois <pfdubois at gmail.com> wrote:
> And yes, I think FFT is a name. (:->  Exception for that.


There are more exceptions that Numeric is not taking advantage of:

equal, less, greater, ... -> eq, lt, gt, ...
inverse, generalized_inverse -> inv, pinv

In my view it is more important that code is easy to read rather than
easy to write. Interactive users will disagree, but in programming you
write once and read/edit forever :).

Again, there is no defense for abbreviating linear_least_squares
because it is unlikely to appear in an expression and waste valuable
horisontal space.  Contracting generalised_inverse is appropriate and
numpy does the right thing in this case.

The eig.., svd and cholesky choice of names is unfortunate because
three different abbreviation schemes are used: first syllable,
acronym and first word.  I would say: when in doubt spell it in full.




More information about the NumPy-Discussion mailing list