Last active
October 24, 2017 21:31
-
-
Save GuiMarthe/68ac1044a367c95f3ccfd1549a87f5c9 to your computer and use it in GitHub Desktop.
quick log odds, odds, probability equivalence
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
library(dplyr) | |
tibble( | |
prob = seq(0, 1, 0.01), | |
complement = 1 - prob, | |
odds_ratio = prob/complement, | |
log_odds_ratio = log(odds_ratio) | |
) %>% | |
arrange(-abs(log_odds_ratio)) %>% | |
print(n = nrow(.)) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment