plot_posterior: Plot posterior probability distribution and display posterior...

plot_posteriorR Documentation

Plot posterior probability distribution and display posterior parameters for an object of class Counts

Description

Plot posterior probability distribution and display posterior parameters for an object of class Counts

Usage

plot_posterior(object, low = 0.025, up = 0.975, xlab, step, ...)

Arguments

object

object of class Counts

low

1 - right tail posterior probability

up

left tail posterior probability

xlab

x-axis label. Default to 'n' (no label)

step

integer defining the increment for x-axis labels (distance between two consecutive tick marks)

...

additional parameters to be passed to curve

Value

no return value, called for side effects

Author(s)

Federico Comoglio

References

Comoglio F, Fracchia L and Rinaldi M (2013) Bayesian inference from count data using discrete uniform priors. PLoS ONE 8(10): e74388

Examples

counts <- new_counts(counts = c(20,30), fractions = c(0.075, 0.10))

# default parameters ("dup" algorithm, sampling without replacement, default prior support)
posterior <- compute_posterior(counts)

# plot posterior
plot_posterior(posterior, type = 'l', lwd = 3, col = 'blue3')


dupiR documentation built on May 29, 2024, 1:21 a.m.