TAMO.util.Arith
index
/home/David_Gordon/docs/TAMO/util/Arith.py

#Copyright (2005) Whitehead Institute for Biomedical Research (except as noted below)
#All Rights Reserved
#
#Author: David Benjamin Gordon

 
Modules
       
math
sys

 
Functions
       
avestd(vals)
binomial(frac_exp, draws, hits)
(frac,draws,hits) Binomial theorem expectation of getting exact number of hits
binomialsumtail(frac_exp, draws, hits)
(frac,draws,hits) Sum of the tail of the binomial distribution
fact(a)
fact(a)
hypgeomsummore(numinteresting, total, numpicked, numfound)
hypgeomsummore (numinteresting, total, numpicked, numfound)
lzprob(z)
Returns the area under the normal curve 'to the left of' the given z value.
Thus, 
    for z<0, zprob(z) = 1-tail probability
    for z>0, 1.0-zprob(z) = 1-tail probability
    for any z, 2.0*(1.0-zprob(abs(z))) = 2-tail probability
Adapted from z.c in Gary Perlman's |Stat by Gary Strangman in stats.py
General Public License (GPL) v2, https://www.gnu.org/copyleft/gpl.html
 
Usage:   lzprob(z)
median(vals)
nlog10(x, min=9.9999999999999999e-300)
norm_pvalue(ave, std, obs)
rank_pvalue(obs, values)
stircomb(x, y)
stircomb (x,y)
stirhypgeom(numinteresting, total, numpicked, numfound)
stirhypgeom (numinteresting, total, numpicked, numfound)
stirling(n)
stirling(n)  (approximationg of log(n!))