gold_pp: Plot the Prior vs. the Posterior

Description Usage Arguments Details Value Examples

Description

Plots the histograms and densities of simulations from the prior verses the posterior from gold.

Usage

1
gold_pp(gold_output, npar = 9, burnin = NA)

Arguments

gold_output

The list returned by gold containing the density estimate results.

npar

The number of paramters to plot. 3X3 grids of tracepltos are created (DEFAULT is 9).

burnin

The desired burnin to discard from the results. By default it is half the number of iterations.

Details

If npar is specified to be 9, 9 paramters (as equally spaced as possible) are chosen to plot.

Value

A plot of histograms.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
## --------------------------------------------------------------------------------
## Beta Distribution
## --------------------------------------------------------------------------------

# First run 'duos' on data sampled from a beat(2,5) distribution with 50 data points.
y <- rbeta(50, 2, 5)
duos_beta <- duos(y, k=4, MH_N=20000)

#Plot histograms of the priors vs. the posteriors of the cut-point parameters 
duos_pp(duos_beta)

#Plot histograms of the priors vs. the posteriors of the proportion parameters 
duos_pp(duos_beta, parameters = "p")

reykp/biRd documentation built on May 17, 2019, 8:16 p.m.