HP filtered data : level of growth?

Previously, I just computed growth rates, and now, I want to use HP-filtered data
because the model I am trying to estimate does not satisfy balanced growth path,

For example, in the past, I computed output growth rate which is just the 100*log difference of output. (% change).
Now, I obtained output cycle by HP-filtering GDP and the problem is how to code this data into my observational equations.

In other words, let computed filterd gdp (data) as A,
Now, I have to code the measurement equation for “y_t (model variable of output)” in dynare.
The problem is, I am not sure whether “A = y_t” or “A = y_t-y_t(-1)”.

Please help.

Please consult Pfeifer(2013): “A Guide to Specifying Observation Equations for the Estimation of DSGE Models”

  1. It would be
A = y_t

is your model is linearized, i.e. if y_t measures percentage deviations from trend and you HP-filtered the log level.
2. You should never use the two-sided HP-filter for Bayesian estimation. Use the one-sided one or simply demeaned growth rates.

Thank you.
I have some additional questions.

I have got a comment that since I do not assume a trend in the quantity variables in my model, I should use detrended data using linear detrending or HP-filter instead of growth rates.

However, according to your comment, demeaning the data might be another way of detrending.
Is this correct?

Also, I would like to know whether I must not use prefilter=1 (demeaning the data) when I use data detrended by HP-filtering or linear.

Thank you.
I have some additional questions.

I have got a comment that since I do not assume a trend in the quantity variables in my model, I should use detrended data using linear detrending or HP-filter instead of growth rates.

However, according to your comment, demeaning the data might be another way of detrending.
Is this correct?

Also, I would like to know whether I must not use prefilter=1 (demeaning the data) when I use data detrended by HP-filtering or linear.

  1. If you use a filter that has already demeaned the data, do not use prefilter (it will be redundant)
  2. I did not say you should simply demean a trending data series. What I said is to demean the growth rates of the trending variable. That takes care of the different growth rates in the sample coming with non-balanced growth. See Remark 14 (Cointegration Relationships) in the document linked above.
  3. The one-sided HP-filter and a linear/quadratic trend would also be fine. The important part is to conceptualize what you consider the frequencies your model is supposed to explain and then remove the rest. That determines which filter/detrending method you should use.

Regarding 2,
the “trending data” you mentioned is the data with trend, right?
I simply computed a growth rate and its demeaned data (by coding prefilter=1) and some people commented that I should use its detrended level instead of just its growth rate.

My question is that whether demeaning itself is anouther way of detrending.

Next, one variable ‘A’ in my model is stationary only in its growth rate (dA).
In fact, my model do not want A but dA (=A-A(-1)) plays an important role, so that it does not matter actually.
However, when I code dA = A - A(-1) in dynare as a measurement equation, I must use diffuse_filter because A is not stationary. So, I decided to use its growth rate data directly without imposing the measurement equation.

Then, a problem occurs in computing the growth rate of HP-filtered ‘A’ because the HP-filtered series has negative value.

So, I computed its growth rate according to

  1. Obtain HP-filtered A. (A is already log value).
  2. Then, multiply 100 to have percentage deviation from its trend. => A_100
  3. Finally, I calculated its growth rate dA = ((A_100 - A_100(-1))/A_100(-1)). (I did not multiply 100 in this case because A_100 is already %).

Is this correct?