[Numpy-discussion] Name change of the ptp() function

Eli Bressert ebressert at gmail.com
Fri May 10 09:04:35 EDT 2013


That's a good point regarding the range function names. But, I think
the issue still stands on the readability of the ptp function.
Regarding PEP20 it's stated that "readability counts."

If you regard what ptp is supposed to replace, array.max() -
array.min(), the aforementioned follows the PEP20 better as it is more
readable. If valuerange() is not an acceptable name, maybe span()?

-Eli


On Fri, May 10, 2013 at 10:44 PM, Pauli Virtanen <pav at iki.fi> wrote:
> 10.05.2013 08:47, Eli Bressert kirjoitti:
> [clip: renaming ptp]
>> valuerange() appears to the best most favored one.
>
> range(), arange(), valuerange()
>
> I'm not really a big fan of changing the name of this function at this
> stage, as it seems to me that whether it's a gain or not is somewhat a
> matter of taste.
>
> --
> Pauli Virtanen
>
> _______________________________________________
> NumPy-Discussion mailing list
> NumPy-Discussion at scipy.org
> http://mail.scipy.org/mailman/listinfo/numpy-discussion



More information about the NumPy-Discussion mailing list