[Numpy-discussion] Was the range() function ever created?

C W tmrsg11 at gmail.com
Fri May 24 23:48:53 EDT 2019


I can't be the first person who asked about range() that calculates the
*actual* range of two numbers.

I have not used numpy or pandas long enough to know, but how has it been
dealt with before?

On Fri, May 24, 2019 at 11:10 PM Benjamin Root <ben.v.root at gmail.com> wrote:

> pandas is not built on numpy (at least, not anymore), but borrows a lot of
> inspirations from numpy, and interacts with numpy fairly well. As part of
> the scipy ecosystem, we all work together to improve interoperability and
> features.
>
> python's built-in range() function has been there long before numpy came
> on the scene, so it just made sense to adopt that name since it was the way
> to generate numbers in python.
>
> Ben
>
> On Fri, May 24, 2019 at 10:44 PM C W <tmrsg11 at gmail.com> wrote:
>
>> When I looked up pandas mailing list. Numpy showed up. Maybe is because
>> Pandas is built on Numpy? My apologies.
>>
>> Yes, please do. For people with statistical background, but not CS. It
>> seems strange the *real* range() function is used to generate natural
>> numbers.
>>
>> Thanks, Ben!
>>
>>
>>
>> On Fri, May 24, 2019 at 10:34 PM Benjamin Root <ben.v.root at gmail.com>
>> wrote:
>>
>>> This is the numpy discussion list, not the pandas discussion list. Now,
>>> for numpy's part, I have had hankerings for a `np.minmax()` ufunc, but
>>> never enough to get over just calling min and max on my data separately.
>>>
>>> On Fri, May 24, 2019 at 10:27 PM C W <tmrsg11 at gmail.com> wrote:
>>>
>>>> Hello all,
>>>>
>>>> I am want to calculate the range of a vector. I saw that someone asked
>>>> for range() in 2011, but was it ever created?
>>>> https://github.com/pandas-dev/pandas/issues/288
>>>>
>>>> Response at the time was to use df.describe(). But df.describe() gives
>>>> all the 5-number summary statistics, but I DON'T WANT wall the extra stuff
>>>> I didn't ask for. I was expected a numerical number. I can use that to feed
>>>> into another function.
>>>>
>>>> It exists in Matlab and R, why not in Python? I'm quite frustrated
>>>> every time I need to calculate the range.
>>>>
>>>> Thanks in advance.
>>>>
>>>>
>>>>
>>>>
>>>> _______________________________________________
>>>> NumPy-Discussion mailing list
>>>> NumPy-Discussion at python.org
>>>> https://mail.python.org/mailman/listinfo/numpy-discussion
>>>>
>>> _______________________________________________
>>> NumPy-Discussion mailing list
>>> NumPy-Discussion at python.org
>>> https://mail.python.org/mailman/listinfo/numpy-discussion
>>>
>> _______________________________________________
>> NumPy-Discussion mailing list
>> NumPy-Discussion at python.org
>> https://mail.python.org/mailman/listinfo/numpy-discussion
>>
> _______________________________________________
> NumPy-Discussion mailing list
> NumPy-Discussion at python.org
> https://mail.python.org/mailman/listinfo/numpy-discussion
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/numpy-discussion/attachments/20190524/912fc387/attachment.html>


More information about the NumPy-Discussion mailing list