plot_binomial_likelihood function

Plot a Binomial Likelihood Function

Plot a Binomial Likelihood Function

Plots the Binomial likelihood function for variable π\pi

given y observed successes in a series of n Binomial trials.

plot_binomial_likelihood(y, n, mle = FALSE)

Arguments

  • y: number of successes
  • n: number of trials
  • mle: a logical value indicating whether maximum likelihood estimate of π\pi, y/n, should be plotted

Returns

a ggplot

Examples

plot_binomial_likelihood(y = 3, n = 10, mle = TRUE)