expit | R Documentation |

Compute the `expit`

and `logit`

of a numerical vector. Transform odds to probability.

expit(x) logit(x) odds(x)

`x` |
vector of real values. |

`logit`

computes the logit function:

*logit(p) = log(p/(1-p)),*

`expit`

computes the expit function:

*expit(x) = e^x/(1+e^x).*

`odds`

transform an odd into a probability.

*odds(x) = x/(1-x)*

Those functions become numerically unstable if evaluated at the edge or the definition range.

A real vector corresponding to the expit, the logit or the odds of the input values.

Gilles Kratzer

Embedding an R snippet on your website

Add the following code to your website.

For more information on customizing the embed code, read Embedding Snippets.