search for: lbeta

Displaying 20 results from an estimated 32 matches for "lbeta".

Did you mean: beta
1997 May 05
0
R-beta: R 0.49 -- "funny" bug: beta(.) gives lbeta(.); lbeta(a,b) gives a
[I send this to R-help, since the bug may affect users..] The beta(.) and ln(beta(..)) functions are not giving proper results in R-0.49. This does NOT affect usual beta-distribution calculations, since the internal beta(.) and lbeta(.) are okay. beta(1,2) [1] -0.6931472 exp(beta(1,2)) [1] 0.5 lbeta(3,4) [1] 3 ------- For R-devel'ers : Using gdb clearly shows that beta(.) really uses the C function lbeta(.) and lbeta(.) doesn't call either one. The bug has already been in 0.50--"pre 3", but is not...
1997 Jun 25
3
R-alpha: lbeta, ctrl-C and crashes
1. lbeta and beta do not work properly: lbeta returns its first argument and beta gives the lbeta result. In names.c lines 245-6, the codes for these should be 2 and 3 instead of 1 and 2 2. crtl-C does not work (except the first time) on Red Hat elf Linux (which has many many other problems as well) nor o...
1997 Jun 25
3
R-alpha: lbeta, ctrl-C and crashes
1. lbeta and beta do not work properly: lbeta returns its first argument and beta gives the lbeta result. In names.c lines 245-6, the codes for these should be 2 and 3 instead of 1 and 2 2. crtl-C does not work (except the first time) on Red Hat elf Linux (which has many many other problems as well) nor o...
2010 Aug 03
2
incorrect number of dimensions
Hi, How to solve this problem. The following is the code. betabinexch0=function(theta,data) + { + eta=theta[,1] + K=theta[,2] + y=data[,1]; n=data[,2] + N=length(y) + val=0*K; + for (i in 1:N) + val=val+lbeta(K*eta+y[i],K*(1-eta)+n[i]-y[i]) + val=val-N*lbeta(K*eta,K*(1-eta)) + val=val-2*log(1+K)-log(eta)-log(1-eta) + return(val) + } > data(cancermortality) > mycontour(betabinexch0,c(.0001,.003,1,20000),cancermortality) Error in theta[, 1] : incorrect number of dimensions [[alternativ...
2012 Nov 22
1
Optimizing nested function with nlminb()
I am trying to optimize custom likelyhood with nlminb() Arguments h and f are meant to be fixed. example.R: compute.hyper.log.likelyhood <- function(a, h, f) { a1 <- a[1] a2 <- a[2] l <- 0.0 for (j in 1:length(f)) { l <- l + lbeta(a1 + f[j], a2 + h - f[j]) - lbeta(a1, a2) } return(l) } compute.optimal.hyper.params <- function(start, limits, h_, f_) { result <- nlminb(start, compute.hyper.log.likelyhood, h=h_, f=f_, scale = -1,...
2008 Aug 21
1
pnmath compilation failure; dylib issue?
...h.so bd0.o beta.o chebyshev.o choose.o d1mach.o dbeta.o dbinom.o dcauchy.o dchisq.o dexp.o df.o dgamma.o dgeom.o dhyper.o dlnorm.o dlogis.o dnbeta.o dnbinom.o dnchisq.o dnf.o dnorm.o dnt.o dpois.o dt.o dunif.o dweibull.o fmax2.o fmin2.o ftrunc.o gamma.o gamma_cody.o i1mach.o imax2.o imin2.o lbeta.o lgamma.o lgammacor.o mlutils.o pbeta.o pbinom.o pcauchy.o pchisq.o pexp.o pf.o pgamma.o pgeom.o phyper.o plnorm.o plogis.o pnbeta.o pnbinom.o pnchisq.o pnf.o pnmath.o pnorm.o pnt.o polygamma.o ppois.o pt.o ptukey.o punif.o pweibull.o qbeta.o qbinom.o qcauchy.o qchisq.o qexp.o qf.o qgamma....
2000 Aug 26
0
Re: [R] too large alpha or beta in dbeta ? (PR#643)
...= 0; double xmin; + if (xmax == 0) + gammalims(&xmin, &xmax); #endif + if (a <= 0 || b <= 0) ML_ERR_return_NAN; if (x < 0 || x > 1) @@ -35,10 +43,13 @@ if (x < 0 || x > 1) return R_D__0; + +#define R_LOG_DBETA log(x)*(a - 1) + log(1 - x)*(b - 1) - lbeta(a, b) - if(give_log) { - return log(x)*(a - 1) + log(1 - x)*(b - 1) - lbeta(a, b); - } + if(give_log) + return R_LOG_DBETA; + else if (a + b >= xmax) /* beta(a,b) might be = 0 numerically */ + return exp(R_LOG_DBETA); else { double y; y = beta(a, b); ------ Martin Maechl...
2000 Aug 28
0
Re: [R] too large alpha or beta in dbeta ? (PR#643)
...= 0; double xmin; + if (xmax == 0) + gammalims(&xmin, &xmax); #endif + if (a <= 0 || b <= 0) ML_ERR_return_NAN; if (x < 0 || x > 1) @@ -35,10 +43,13 @@ if (x < 0 || x > 1) return R_D__0; + +#define R_LOG_DBETA log(x)*(a - 1) + log(1 - x)*(b - 1) - lbeta(a, b) - if(give_log) { - return log(x)*(a - 1) + log(1 - x)*(b - 1) - lbeta(a, b); - } + if(give_log) + return R_LOG_DBETA; + else if (a + b >= xmax) /* beta(a,b) might be = 0 numerically */ + return exp(R_LOG_DBETA); else { double y; y = beta(a, b); ------ Martin Maechl...
2000 Nov 28
1
non-centrality parameter in pf() (PR#752)
Bug Description: Problem with the function pf() when the non-centrality parameter is large. Here is a sample command. You should see a smooth line from 0 to about 55, and then the values of pf() go crazy from 55 to 100. ############################ ncp <- seq(0,100,length=200) plot(ncp,pf(5,7,2,ncp=ncp)) ############################ Version: platform = i686-pc-linux-gnu arch = i686 os =
2008 Jan 29
1
The standalone Rmath library and VC++ 2003
...s.o) : warning LNK4217: locally defined symbol __iob imported in function _REprintf libRmath.a(dbeta.o) : error LNK2019: unresolved external symbol _log1p referenced in function _dbeta libRmath.a(qbeta.o) : error LNK2019: unresolved external symbol _log1p referenced in function _qbeta libRmath.a(lbeta.o) : error LNK2019: unresolved external symbol _log1p referenced in function _lbeta libRmath.a(toms708.o) : error LNK2001: unresolved external symbol _log1p libRmath.a(qbeta.o) : error LNK2019: unresolved external symbol _expm1 referenced in function _qbeta libRmath.a(mlutils.o) : error LNK2019:...
1998 Oct 25
2
EGCS optimizer bug?
.....) The following paraphrase on R's qbeta.c appears to be a close to minimal example of the problem (no, it doesn't do anything useful, and there are several obvious things wrong with it, but it displays the %ebx problem, if you look at the generated code): #include <math.h> double lbeta(){} double qbeta(double alpha, double p, double q) { double t,r, logbeta; volatile double xinbta; logbeta = lbeta(p, q); if (p<1) t = r * pow(t, 3.); return xinbta; } main(){qbeta(.5,.5,.5);} [pd@butterfly sandbox]$ egcs -O qbeta.c -...
2009 Mar 17
3
R does not compile any more on FreeBSD 8.0-CURRENT
...e -DHAVE_CONFIG_H -g -O2 -c signrank.c -o signrank.o rm -rf libnmath.a ar cr libnmath.a mlutils.o d1mach.o i1mach.o fmax2.o fmin2.o fprec.o fround.o ftrunc.o sign.o fsign.o imax2.o imin2.o chebyshev.o log1p.o expm1.o lgammacor.o gammalims.o stirlerr.o bd0.o gamma.o lgamma.o gamma_cody.o beta.o lbeta.o polygamma.o bessel_i.o bessel_j.o bessel_k.o bessel_y.o choose.o snorm.o sexp.o dgamma.o pgamma.o qgamma.o rgamma.o dbeta.o pbeta.o qbeta.o rbeta.o dunif.o punif.o qunif.o runif.o dnorm.o pnorm.o qnorm.o rnorm.o dlnorm.o plnorm.o qlnorm.o rlnorm.o df.o pf.o qf.o rf.o dnf.o dt.o pt.o qt.o rt.o dn...
2002 Jan 22
1
compile problem with bessel_i.c on IRIX64 flexor 6.5 10100655 IP35 (uname -a) (PR#1275)
...chebyshev.c making log1p.d from log1p.c making lgammacor.d from lgammacor.c making gammalims.d from gammalims.c making stirlerr.d from stirlerr.c making bd0.d from bd0.c making gamma.d from gamma.c making lgamma.d from lgamma.c making gamma_cody.d from gamma_cody.c making beta.d from beta.c making lbeta.d from lbeta.c making polygamma.d from polygamma.c making bessel_i.d from bessel_i.c making bessel_j.d from bessel_j.c making bessel_k.d from bessel_k.c making bessel_y.d from bessel_y.c making choose.d from choose.c making snorm.d from snorm.c making sexp.d from sexp.c making dgamma.d from dgamma....
1997 Dec 13
1
R-beta: Compile error; R-0.60.1, Solaris 2.6, gcc 2.7.2.1
...c -o round.o gcc -g -I../include -c prec.c -o prec.o gcc -g -I../include -c sign.c -o sign.o gcc -g -I../include -c i1mach.c -o i1mach.o gcc -g -I../include -c d1mach.c -o d1mach.o gcc -g -I../include -c beta.c -o beta.o gcc -g -I../include -c gamma.c -o gamma.o gcc -g -I../include -c lbeta.c -o lbeta.o gcc -g -I../include -c lgamma.c -o lgamma.o gcc -g -I../include -c choose.c -o choose.o gcc -g -I../include -c dpsifn.c -o dpsifn.o gcc -g -I../include -c digamma.c -o digamma.o gcc -g -I../include -c sexp.c -o sexp.o gcc -g -I../include -c snorm.c -o snorm.o gcc -g -I../in...
1999 May 03
1
problems compiling R-0.63.3 on alpha
...t -g -I../include -I../../src/include -c lgamma.c -o lgamma.o gcc -ieee_with_inexact -g -I../include -I../../src/include -c gamma_cody.c -o gamma_cody.o gcc -ieee_with_inexact -g -I../include -I../../src/include -c beta.c -o beta.o gcc -ieee_with_inexact -g -I../include -I../../src/include -c lbeta.c -o lbeta.o gcc -ieee_with_inexact -g -I../include -I../../src/include -c polygamma.c -o polygamma.o gcc -ieee_with_inexact -g -I../include -I../../src/include -c bessel_i.c -o bessel_i.o gcc -ieee_with_inexact -g -I../include -I../../src/include -c bessel_j.c -o bessel_j.o gcc -ieee_with_i...
2013 Mar 01
0
R 2.15.3 is released
...supplied in the JDK and system libraries. This can always be overridden if needed: see the 'R Installation and Administration' manual. BUG FIXES: o beta(a, b) could overflow to infinity in its calculations when one of a and b was less than one. (PR#15075) o lbeta(a, b) no longer gives NaN if a or b is very small (in the denormalized range). o bquote() is now able to substitute default arguments in single-argument functions. (PR#15077) o browseEnv(html = FALSE) would segfault if called from R (not R.app) on a CRAN-style Mac OS X...
2013 Mar 01
0
R 2.15.3 is released
...supplied in the JDK and system libraries. This can always be overridden if needed: see the 'R Installation and Administration' manual. BUG FIXES: o beta(a, b) could overflow to infinity in its calculations when one of a and b was less than one. (PR#15075) o lbeta(a, b) no longer gives NaN if a or b is very small (in the denormalized range). o bquote() is now able to substitute default arguments in single-argument functions. (PR#15077) o browseEnv(html = FALSE) would segfault if called from R (not R.app) on a CRAN-style Mac OS X...
1998 Nov 06
1
DEC alpha INSTALLATION R-0.62.4
...de -c lgammacor.c cc -ieee_with_inexact -g -I../../src/include -c gammalims.c cc -ieee_with_inexact -g -I../../src/include -c gamma.c cc -ieee_with_inexact -g -I../../src/include -c lgamma.c cc -ieee_with_inexact -g -I../../src/include -c beta.c cc -ieee_with_inexact -g -I../../src/include -c lbeta.c cc -ieee_with_inexact -g -I../../src/include -c polygamma.c cc -ieee_with_inexact -g -I../../src/include -c choose.c cc -ieee_with_inexact -g -I../../src/include -c snorm.c cc -ieee_with_inexact -g -I../../src/include -c sunif.c cc -ieee_with_inexact -g -I../../src/include -c sexp.c cc -ieee...
1999 May 03
0
compilation of R-0.63.3 on alpha (PR#183)
...clude -I../../src/include -c lgamma.c -= o = lgamma.o gcc -ieee_with_inexact -g -I../include -I../../src/include -c gamma_cody= =2Ec -o = gamma_cody.o gcc -ieee_with_inexact -g -I../include -I../../src/include -c beta.c -o = beta.o gcc -ieee_with_inexact -g -I../include -I../../src/include -c lbeta.c -o= = lbeta.o gcc -ieee_with_inexact -g -I../include -I../../src/include -c polygamma.= c -o = polygamma.o gcc -ieee_with_inexact -g -I../include -I../../src/include -c bessel_i.c= -o = bessel_i.o gcc -ieee_with_inexact -g -I../include -I../../src/include -c bessel_j.c= -o = bessel_j.o...
1998 Dec 08
0
R compile problems with AIX
...../../src/include -c gamma.c -o gamma.o gcc -g -O2 -I../include -I../../src/include -c lgamma.c -o lgamma.o gcc -g -O2 -I../include -I../../src/include -c gamma_cody.c -o gamma_cody.o gcc -g -O2 -I../include -I../../src/include -c beta.c -o beta.o gcc -g -O2 -I../include -I../../src/include -c lbeta.c -o lbeta.o gcc -g -O2 -I../include -I../../src/include -c polygamma.c -o polygamma.o gcc -g -O2 -I../include -I../../src/include -c bessel_i.c -o bessel_i.o gcc -g -O2 -I../include -I../../src/include -c bessel_j.c -o bessel_j.o gcc -g -O2 -I../include -I../../src/include -c bessel_k.c -o bes...