R code for assessing diagnostics of Monte Carlo Markov Chains