How to obtain trace plots after a Metropolis-Hastings

It can be useful to plot iterations vs. sampled values for each variable (parameter) in a chain. If the Metropolis-Hastings converges to a stable distribution, the trace plot has to be stable (e.g. no trend in the sampled values).

After a metropolis (that is after the estimation command in the mod file) you just have to write:

trace_plot(options_,M_,estim_params_,type,blck,name1,name2)

where:

After the estimation of the model in fs2000.mod if we want to build a trace plot for parameter alp, we just have to write:

trace_plot(options_,M_,estim_params_,'DeepParameter',2,'alp')

and the following plot will pop up:

attachment:trace_plot.jpg