Dear professor jpfeifer,
I got three questions on one side HP-filter and model fit to real data:
First, when doing Bayesian estimation, the real data (e.g. real output “y”) are first seasonally adjust, then take the log of the data and apply the one-sided HP-filter. My question is we can not use the one-sided HP-filter in Eviews as it is two-sided HP-filter, it must be done in Matlab, right? Can you give me an example code for one-side HP-filter of Matlab?
Second, if variable of the code is written in level, the observation is then : yobs=log(y)-log(steadystate y), where yobs is oberved variable (the data after first seasonally adjust, take log, one-sided HP-filter), is this right?
Third, when judging whether the estimation result fit the real data well, as the variable of the code is in level, I add log_y in “Definition of variables” , use the code "stoch_simul(order=1,hp_filter=1600); log_y ", then compare the theoritical moments (S.D or Correlations) with the statistics of the real data, is this right?
Really hope for your reply which always help me a lot, thank you, professor.
Best.