Because np.mean() is ddof=0? (I mean effectively, not that it actually has a parameter for that) There is consistency within the library, and I certainly wouldn't want to have NaN all of the sudden coming from my calls to mean() that I apply to an arbitrary non-empty array of values that happened to have only one value. So, if we can't change the default for mean, then it only makes sense to keep np.std() consistent with np.mean().
My 2 cents... Ben Root On Tue, Apr 1, 2014 at 2:27 PM, Haslwanter Thomas < [email protected]> wrote: > While most other Python applications (scipy, pandas) use for the > calculation of the standard deviation the default "ddof=1" (i.e. they > calculate the sample standard deviation), the Numpy implementation uses the > default "ddof=0". > > Personally I cannot think of many applications where it would be desired > to calculate the standard deviation with ddof=0. In addition, I feel that > there should be consistency between standard modules such as numpy, scipy, > and pandas. > > > > I am wondering if there is a good reason to stick to "ddof=0" as the > default for "std", or if others would agree with my suggestion to change > the default to "ddof=1"? > > > > Thomas > > > > --- > Prof. (FH) PD Dr. Thomas Haslwanter > School of Applied Health and Social Sciences > > *University of Applied Sciences* *Upper Austria* > *FH OÖ Studienbetriebs GmbH* > Garnisonstraße 21 > 4020 Linz/Austria > Tel.: +43 (0)5 0804 -52170 > Fax: +43 (0)5 0804 -52171 > E-Mail: [email protected] > Web: me-research.fh-linz.at <http://work.thaslwanter.at> > or work.thaslwanter.at > > > > _______________________________________________ > NumPy-Discussion mailing list > [email protected] > http://mail.scipy.org/mailman/listinfo/numpy-discussion > >
_______________________________________________ NumPy-Discussion mailing list [email protected] http://mail.scipy.org/mailman/listinfo/numpy-discussion
