odds_to_probs.Rd
This is the inverse of the function that calculates odds from probabilities.
For any given value of odds, the corresponding probability p
where
odds = p/(1-p)
is returned.
odds_to_probs(odds)
odds | A numeric vector of non-negative values, representing odds. |
---|
A numeric vector of probabilities.
odds <- c(1, 3, 9) odds_to_probs(odds) #> [1] 0.50 0.75 0.90