[SciPy-dev] RFR: Proposed fixes in scipy.stats functions for calculation of variance/error/etc.

josef.pktd@gmai... josef.pktd@gmai...
Sun Oct 25 22:16:35 CDT 2009


On Sun, Oct 25, 2009 at 10:50 PM, Ariel Rokem <arokem@berkeley.edu> wrote:
> Hi everyone,
>
> I have been working on some fixes to the functions in scipy.stats
> which calculate variance/error and related quantities. In particular,
> in order to comply with the deprecation warnings that appear in use of
> scipy.stats.samplevar/scipy.stats.samplestd, I have replaced use of
> these functions with calls to np.std/np.var. I have also cleaned up
> the documentation a bit.
>
> This can all be found here: http://codereview.appspot.com/141051
>
> Cheers,
>
> Ariel

I just gave it a quick look, looks good so far

in  def zs  looks like a shape error for axis>0
"return (a-mu)/sigma"


def zs   changes definition, before it normalized with raveled mean,
std not by axis

- mu = np.mean(a,None)
- sigma = samplestd(a)
- return (array(a)-mu)/sigma

+ a,axis = _chk_asarray(a,axis)
+ mu = np.mean(a,axis)
+ sigma = np.std(a,axis)
+ return (a-mu)/sigma

I never looked closely at these,
zmap has a description I don't understand.

z, zs, zm  ???

Which is which? they look a bit inconsistent, population might refer
to dof correction in z ?
Is there a standard terminology for z scores?

I think for axis, I have seen more "int or None" ?

Josef




> --
> Ariel Rokem
> Helen Wills Neuroscience Institute
> University of California, Berkeley
> http://argentum.ucbso.berkeley.edu/ariel
> _______________________________________________
> Scipy-dev mailing list
> Scipy-dev@scipy.org
> http://mail.scipy.org/mailman/listinfo/scipy-dev
>


More information about the Scipy-dev mailing list