logit: Univariate Logistic and Inverse Logistic Transformation

Description Usage Arguments Details Value See Also Examples

View source: R/utils.r

Description

Transforms a vector of numeric values from logistic space [0,1] to the real line (-Inf,Inf) ... and vice versa.

Usage

1
2

Arguments

p

a vector of probabilities

x

a vector probabilities on the logistic scale

Details

Calculations are based on the tanh and atanh function.

Value

Either a vector of values on the real line for logit or a vector of probabilities for inv.logit

See Also

atan atanh

Examples

1
2
  (x <- logit(c(-Inf, 0.5, Inf)))
  inv.logit(x)

myFuncs documentation built on May 2, 2019, 4:53 p.m.