R/logit.R

Defines functions logit

Documented in logit

#' Logit Function
#'
#' This function carries out the usual logit(p)=log(p/(1-p)) function
#' @param TRUE.
#' @keywords logit
#' @export
#' @examples
#' logit(0.6)

logit <- function(p)
  {
  if (p<0 | p>1) stop("value is not in [0,1]")
  log(p/(1-p))}
daniel258/Daniel documentation built on May 9, 2023, noon