Bayesian estimation with MCMC

Dear all,
I am trying to do Bayesian estimation with MCMC,Estimation seems to work properly,However, the Estimation:mcmc:diagnostics:does not work and returns an error
Estimation::mcmc::diagnostics: Univariate convergence diagnostic, Brooks and Gelman (1998):
Parameter 1… ??? Attempted to access temp(-6298,1); index must be a positive integer or
logical.

Error in ==> McMCDiagnostics_core at 105
UDIAG(ligne,1,j-fpar+1) = temp(CSUP,1)-temp(CINF,1);

Error in ==> McMCDiagnostics at 173
fout = McMCDiagnostics_core(localVars,1,npar,0);

Error in ==> dynare_estimation_1 at 793
oo_= McMCDiagnostics(options_, estim_params_, M_,oo_);

Error in ==> dynare_estimation at 89
dynare_estimation_1(var_list,dname);

Error in ==> estimatingfinal at 1014
dynare_estimation(var_list_);

Error in ==> dynare at 180
evalin(‘base’,fname) ;

Thank you so much!

I would very much appreciate if anyone could help with this matter.

dear all,
I am having a hard time to work with modle file in matlab. Can someone tell me what I am doing wrong here.
Thank you for any help or suggestion!

Dear all,
I am trying to do Bayesian estimation with MCMC.However, the Estimation:mcmc:diagnostics:does not work and returns an error, Can someone tell me what I am doing wrong here.
Thank you for any help or suggestion!
Estimation::mcmc::diagnostics: Univariate convergence diagnostic, Brooks and Gelman (1998):
Parameter 1… ??? Attempted to access temp(-6298,1); index must be a positive integer or
logical.

Error in ==> McMCDiagnostics_core at 105
UDIAG(ligne,1,j-fpar+1) = temp(CSUP,1)-temp(CINF,1);

Error in ==> McMCDiagnostics at 173
fout = McMCDiagnostics_core(localVars,1,npar,0);

Error in ==> dynare_estimation_1 at 793
oo_= McMCDiagnostics(options_, estim_params_, M_,oo_);

Error in ==> dynare_estimation at 89
dynare_estimation_1(var_list,dname);

Error in ==> estimatingfinal at 1014
dynare_estimation(var_list_);

Error in ==> dynare at 180
evalin(‘base’,fname) ;

Please provide the files to replicate the issue and state which Dynare version has been used.