File:Odds as function of probability.svg

Summary

Description
English: The graph of odds as a function of probability.
Date
Source Own work
Author ARAKI Satoru
 
W3C-validity not checked.
Category:Unchecked SVG validity
library(ggplot2)
library(latex2exp)

odds <- function(p) p/(1 - p)
e <- 1/10 # 'epsilon'
fig <- ggplot(data.frame(p=c(0, 1)), aes(x=p)) +
  stat_function(fun=odds, size=1.0) +
  scale_x_continuous(limits=c(0+e, 1-e), breaks=seq(0+e, 1-e, by=.2)) +
  scale_y_continuous(limits=c(0, 10), breaks=seq(0, 10, by=2)) +
  labs(x=TeX("$\\mathit{p}$"), y=TeX("$\\mathrm{Odds} = \\mathit{p}/(1 - \\mathit{p})$")) +
  theme_minimal(base_size = 20, base_family = "Times")

svg(filename="odds.svg", width=16, height=9)
plot(fig)
dev.off()

Licensing

I, the copyright holder of this work, hereby publish it under the following license:
w:en:Creative Commons
attribution share alike
This file is licensed under the Creative Commons Attribution-Share Alike 4.0 International license.
You are free:
  • to share – to copy, distribute and transmit the work
  • to remix – to adapt the work
Under the following conditions:
  • attribution – You must give appropriate credit, provide a link to the license, and indicate if changes were made. You may do so in any reasonable manner, but not in any way that suggests the licensor endorses you or your use.
  • share alike – If you remix, transform, or build upon the material, you must distribute your contributions under the same or compatible license as the original.
Category:CC-BY-SA-4.0#Odds%20as%20function%20of%20probability.svg
Category:Self-published work Category:SVG diagrams Category:Ggplot2 Category:Odds Category:Statistics Category:Probability
Category:CC-BY-SA-4.0 Category:Ggplot2 Category:Odds Category:Probability Category:SVG diagrams Category:Self-published work Category:Statistics Category:Unchecked SVG validity