R/pMO.R

Defines functions pMO

Documented in pMO

pMO <-
function(q, theta=1, lower.tail=TRUE, log.p=FALSE)
{
if(theta<0) stop("theta must be less than 0")
Fy <- log(theta)+log(q)-log1p(-(1-theta)*q)
Fy <- ifelse(q <= 0, -Inf, Fy)
Fy <- ifelse(q >= 1, 0, Fy)
if(log.p == FALSE) Fy <- exp(Fy)
if(lower.tail==FALSE) Fy<-1-Fy
Fy
}

Try the gentransmuted package in your browser

Any scripts or data that you put into this service are public.

gentransmuted documentation built on Aug. 8, 2025, 7:21 p.m.