diag_autocorr: Diagnostic: Calculate the autocorrelation for each chain and...

Description Usage Arguments Value Examples

View source: R/diag_autocorr.R

Description

Diagnostic: Calculate the autocorrelation for each chain and parameter

Usage

1
diag_autocorr(x, lags = NULL)

Arguments

x

mcmc.list object or dataframe creatd by mcmc_to_dt

lags

integer the lag value that you want to use

Value

a data.table data frame with the autocorrelation at each lag for each chain and parameter columns lag, acf, chain, and parameter

Examples

1
2
3
4
library(coda)
data(line)
line_acf <- diag_autocorr(line)
line_acf

njtierney/mmcc documentation built on Oct. 5, 2021, 12:14 a.m.