powered by
For a proportion problem with a beta prior, plots the prior, likelihood and posterior on one graph.
triplot(prior,data,where="topright")
vector of parameters for beta prior
vector consisting of number of successes and number of failures
the location of the legend for the plot
# NOT RUN { prior=c(3,10) # proportion has a beta(3, 10) prior data=c(10,6) # observe 10 successes and 6 failures triplot(prior,data) # }
Run the code above in your browser using DataLab