Пример #1
0
 def random(f,p):
     if(f<=0 or f>=1 or p<=0 or p>=1):
         raise ValueError("all inputs must be between 0 and 1 exclusive")
     return beta.random(p*(1-f)/f,(1-p)*(1-f)/f)
Пример #2
0
 def random(g,t,a,b):
     return (1/g)*math.log(1-g/t*math.log(1-beta.random(a,b)))
Пример #3
0
 def random(aa, bb, n):
     if (aa <= 0 or bb <= 0 or n % 1 != 0 or n < 1):
         raise ValueError(
             "aa and bb must be bigger than 0 and n must be a positive integer"
         )
     return binomial.random(n, beta.random(aa, bb))
Пример #4
0
 def random(a, g):
     return math.log(beta.random(a, g))
Пример #5
0
 def random(a, b):
     u = beta.random(a, b)
     return u / (2 - u)
Пример #6
0
 def random(k, m, n):
     return negbin.random(k, beta.random(m, n))
Пример #7
0
 def random(a,b,aa,l):
     v=beta.random(a,b)
     return -math.log(1-math.pow(v,1/aa))/l
Пример #8
0
 def random(a,b,c,d,k):
     u=beta.random(a,b)
     return math.pow(math.pow(1-math.pow(u,1/b),-1/k)-1,1/c)