Plot_trace: Plot the trace plots of the accepted samples.

Description Usage Arguments Value Examples

View source: R/plot_trace.R

Description

This function takes the results from an inference function, and plots the trace plot of all the accepted samples, with a red line to represent the true value if it falls within the limits. If a parameter was fixed it will plot a straight line.

Usage

1
Plot_trace(res, params, burnin = NA)

Arguments

res

The results matrix from the MCMC functions.

params

A named vector of the parameters, with names "beta1", "beta2", "gamma", "d", "p", and "llh".

burnin

The ammount of burnin that wants to be removed (defaults to NA to plot the full trace plots).

Value

A description of the average acceptance probabilities.

Examples

1
Plot_trace(res, params, burnin = NA)

BenjamenSimon/EpidemicR documentation built on March 23, 2020, 11:03 p.m.