Learn R Programming

ggmcmc (version 0.2)

ggs: Manage the output from a coda object to be plotted by ggmcmc and convert it in an object that ggplot understands

Description

Manage the output from a coda object to be plotted by ggmcmc and convert it in an object that ggplot understands

Usage

ggs(S, parallel = TRUE)

Arguments

S
mcmc object from samples
parallel
logical value for using parallel computing when managing the data frame in other functions

Value

  • D data frame with the data arranged and ready to be used by the rest of the ggmcmc functions. The dataframe has four columns, namely: Iteration, Parameter, value and Chain, and four attributes: nChains, nParameters, nIterations, parallel.

Examples

Run this code
# Assign 'D' to be a data frame suitable for ggmcmc functions from
# a coda object called S
data(samples)
D <- ggs(S)        # S is a coda object

Run the code above in your browser using DataLab