Data transformation in DYNARE

I m new to DSGE & Dynare and after reading so many posts from the forum, I m still confuse about the data transformation in DYNARE. Appreciate it if someone can confirm that the correct procedure to transform level form data for estimation? As what I understand, from the level form data, we need to

  1. Log difference
  2. Demean/detrend/HP-filter
    It is the correct way? If yes, then do we still need to use (prefilter=1) in the dynare code?

Thank you very much

Please see Pfeifer(2013): “A Guide to Specifying Observation Equations for the Estimation of DSGE Models” sites.google.com/site/pfeiferecon/Pfeifer_2013_Observation_Equations.pdf.

Prefiltering only takes out the mean, i.e. demeans the data. It does not stationarize the data.