Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #52606

Re: PEP 450 Adding a statistics module to Python

References <520592f9$0$30000$c3e8da3$5496439d@news.astraweb.com> <0d60fd90-eb19-4702-acd5-dd7ba0eddeda@googlegroups.com> <cb7878a8-7700-46a8-b4e8-3f12fdf2cf19@googlegroups.com> <mailman.3.1376673382.23369.python-list@python.org> <55530414-1cf0-46fa-bdce-890d8679b292@googlegroups.com>
From Oscar Benjamin <oscar.j.benjamin@gmail.com>
Date 2013-08-16 20:41 +0100
Subject Re: PEP 450 Adding a statistics module to Python
Newsgroups comp.lang.python
Message-ID <mailman.6.1376682090.23369.python-list@python.org> (permalink)

Show all headers | View raw


On 16 August 2013 20:00,  <chris.barker@noaa.gov> wrote:
>  > > One other point -- for performance reason, is would be nice to have some compiled code in there -- this adds incentive to put it in the stdlib -- external packages that need compiling is what makes numpy unacceptable to some folks.
>>
>> It might be good to have a C accelerator one day but actually I think
>> the pure-Python-ness of it is a strong reason to have it since it
>> provides accurate statistics functions to all Python implementations
>> (unlike numpy) at no additional cost.
>
> Well, I'd rather not have a package that is great for education and  toy problems, but not-so-good for the real ones...

Again it depends what you mean by "real". From the other lists where
we meet I'd guess that your problems are in the "needs a nuclear
reactor" camp. I doubt that the stdlib will ever be sufficiently
mathematically/computationally oriented to fully service either of our
needs (and I don't mean that as a criticism). I persuaded the IT guys
at my work that we needed the whole Enthought Python Distribution on
all machines just because I didn't want to have to argue about
individual packages.

However in my real work, where I compute means and variances etc. I
very often do work with very small datasets and I know a lot of others
who work almost exclusively with them (think e.g. clinical data where
N is often less than 100).

> I guess my point is this:
>
> This is a way to make the standard python distribution better for some common computational tasks. But rather than think of it as "we need some stats functions in the python stdlib", perhaps we should be thinking: "out of the box python should be better for computation" -- in which case, I'd start with a decent array object.

I think that, whether or not the statistics module gains a C
accelerator, if a fast numerical array type comes along then I'd
expect that the statistics module would use its methods as a fast
path. And if it provides a speed boost without compromising
boundedness or accuracy I'm sure that the array type would be used
internally where appropriate (just as numpy converts collections to
arrays before computation).


Oscar

Back to comp.lang.python | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

PEP 450 Adding a statistics module to Python Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2013-08-10 01:10 +0000
  Re: PEP 450 Adding a statistics module to Python Skip Montanaro <skip@pobox.com> - 2013-08-09 22:14 -0500
    Re: PEP 450 Adding a statistics module to Python Roy Smith <roy@panix.com> - 2013-08-10 07:50 -0400
      Re: PEP 450 Adding a statistics module to Python Oscar Benjamin <oscar.j.benjamin@gmail.com> - 2013-08-10 13:23 +0100
        Re: PEP 450 Adding a statistics module to Python Roy Smith <roy@panix.com> - 2013-08-10 08:43 -0400
          Re: PEP 450 Adding a statistics module to Python Oscar Benjamin <oscar.j.benjamin@gmail.com> - 2013-08-10 14:17 +0100
  Re: PEP 450 Adding a statistics module to Python Ben Finney <ben+python@benfinney.id.au> - 2013-08-10 15:05 +1000
  Re: PEP 450 Adding a statistics module to Python Stefan Behnel <stefan_ml@behnel.de> - 2013-08-10 09:55 +0200
  Re: PEP 450 Adding a statistics module to Python Dennis Lee Bieber <wlfraed@ix.netcom.com> - 2013-08-10 16:19 -0400
  Re: PEP 450 Adding a statistics module to Python Skip Montanaro <skip@pobox.com> - 2013-08-11 06:50 -0500
    Re: PEP 450 Adding a statistics module to Python Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2013-08-11 13:33 +0000
    Re: PEP 450 Adding a statistics module to Python Roy Smith <roy@panix.com> - 2013-08-11 10:02 -0400
      Re: PEP 450 Adding a statistics module to Python duncan smith <buzzard@invalid.invalid> - 2013-08-11 16:44 +0100
  Re: PEP 450 Adding a statistics module to Python Nicholas Cole <nicholas.cole@gmail.com> - 2013-08-11 13:27 +0100
  Re: PEP 450 Adding a statistics module to Python Wolfgang Keller <feliphil@gmx.net> - 2013-08-13 20:14 +0200
    Re: PEP 450 Adding a statistics module to Python Oscar Benjamin <oscar.j.benjamin@gmail.com> - 2013-08-13 19:44 +0100
    Re: PEP 450 Adding a statistics module to Python Steven D'Aprano <steve@pearwood.info> - 2013-08-14 06:21 +0000
  Re: PEP 450 Adding a statistics module to Python CM <cmpython@gmail.com> - 2013-08-14 21:26 -0700
    RE: PEP 450 Adding a statistics module to Python "Prasad, Ramit" <ramit.prasad@jpmorgan.com.dmarc.invalid> - 2013-08-16 19:17 +0000
  Re: PEP 450 Adding a statistics module to Python taldcroft@cfa.harvard.edu - 2013-08-16 08:50 -0700
    Re: PEP 450 Adding a statistics module to Python chris.barker@noaa.gov - 2013-08-16 09:31 -0700
      Re: PEP 450 Adding a statistics module to Python Oscar Benjamin <oscar.j.benjamin@gmail.com> - 2013-08-16 18:15 +0100
        Re: PEP 450 Adding a statistics module to Python chris.barker@noaa.gov - 2013-08-16 12:00 -0700
          Re: PEP 450 Adding a statistics module to Python Oscar Benjamin <oscar.j.benjamin@gmail.com> - 2013-08-16 20:41 +0100
      Re: PEP 450 Adding a statistics module to Python Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2013-08-16 18:51 +0000
        Re: PEP 450 Adding a statistics module to Python chris.barker@noaa.gov - 2013-08-16 12:48 -0700
    Re: PEP 450 Adding a statistics module to Python Roy Smith <roy@panix.com> - 2013-08-16 22:06 -0400
      Re: PEP 450 Adding a statistics module to Python Josef Pktd <josef.pktd@gmail.com> - 2013-08-17 05:13 -0700
  Re: PEP 450 Adding a statistics module to Python Jason Friedman <jsf80238@gmail.com> - 2013-08-17 21:57 -0600

csiph-web