R/com.log.density.R

com.log.density <- function (x, lambda, nu, log.z = NULL)
{
  if (lambda < 0 || nu < 0)
    stop("Invalid arguments, only defined for lambda >= 0, nu >= 0")
  if (x < 0 || x != floor(x))
    return(0)
  if (is.null(log.z)) {
    log.z = com.compute.log.z(lambda, nu)
  }
  return((x * log(lambda) - nu * com.log.factorial(x)) - log.z)
}

Try the miRecSurv package in your browser

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

miRecSurv documentation built on Aug. 17, 2021, 5:06 p.m.