I am using the Bayesian estimation algorithm. For six shocks, I use six observable. Smoothed series perfectly match these observable as expected. What is odd is that some other smoothed variables (not used as observable) such as asset prices ( p ) and dividends (d) appear with a negative sign in the oo folder.
On the other hand, in stochastic simulation which follows the estimation, the simulated series for p and d look quite plausible and have the right signs. I wonder whether Kalman smoothing is doing anything strange here or something I am doing wrong.
I attach the code and the dataset for your perusal.
Thanks in advance for your help.