[Numpy-tickets] [NumPy] #461: std/stdp
NumPy
numpy-tickets@scipy....
Sun Mar 4 14:54:05 CST 2007
#461: std/stdp
-------------------------+--------------------------------------------------
Reporter: batripler | Owner: somebody
Type: enhancement | Status: closed
Priority: normal | Milestone:
Component: numpy.lib | Version: 1.0.1
Severity: normal | Resolution: wontfix
Keywords: |
-------------------------+--------------------------------------------------
Changes (by rkern):
* status: new => closed
* resolution: => wontfix
Comment:
As discussed several times before both on this Trac and on the mailing
list, no, we are not going to change this.
For the record, dividing by n-1 is *not* an unbiased estimate of the
standard deviation. Its square is an unbiased estimate of the variance in
the conventional sense of bias. If you use the unconventional, but more
correct, definition of bias for strictly positive quantities like variance
by using log-ratios E(log(v_est/v_true)) instead of simple subtraction
E(v_est - v_true), then the unbiased estimator for both variance and
standard deviation uses n-2, not n-1.
Also, unbiased != better. One may want the maximum likelihood estimator
(n), or the conventional minimum mean squared error (MMSE) estimator
(n+1), or the MMSE estimator using the log-ratio definition of error (n-2
again). Dividing by n is easier to correct to n-1, n-2, n+1 or whatever
estimator the user needs for their application.
We will be happy to accept patches that add a keyword argument to apply a
correction factor to n; however, the default should remain n. While I'm
all in favor of following conventions, I don't want to follow conventions
that demonstrably don't satisfy the reasons that are given for using them.
--
Ticket URL: <http://projects.scipy.org/scipy/numpy/ticket/461#comment:1>
NumPy <http://projects.scipy.org/scipy/numpy>
The fundamental package needed for scientific computing with Python.
More information about the Numpy-tickets
mailing list