The MCMC mode vs the Optimizer Mode

In some cases, i notice that the median or mode that the MCMC produces differs from the one that the optimizer finds.
to recheck, i will initiate the optimizer using the parameter values obtained for the MCMC mode and then the optimizer will go to the another mode.
do other people experience this problem? is there a solution?


I don’t know if this is an answer, but I noted that much depends on data. I solved the problem we were taking about in the previous post. I first used a linear trend to detrend data and I got those problems with the optimizer…Then I tried the HP filter, and now I can run the code as many time as I want and I end up always with same results (same modes, same Laplace, etc.).