Calculates the logit (or log-odds) value of a probability

logit(p)

unlogit(a)

Arguments

p

vector of probabilities between 0 and 1 (exclusive)

a

a numeric vector

Examples

probs <- runif(100) a <- logit(probs) plot(probs, a, xlim = c(0, 1))
probs0 <- unlogit(a) plot(probs, probs0, xlim = c(0, 1), ylim = c(0, 1))