EconPapers    
Economics at your fingertips  
 

Matlab code for one-sided HP-filters

Alexander Meyer-Gohde

QM&RBC Codes from Quantitative Macroeconomics & Real Business Cycles

Abstract: This file contains two different Matlab implementations of one-sided HP-filters. The first is the Kalman implementation laid out by Stock, J.H. and M.W. Watson (1999, p. 301) ["Forecasting inflation," Journal of Monetary Economics, vol. 44(2), pages 293-335, October.] for the optimal one-sided analogue to the standard HP-filter. The second is a serial implementation explained, for example, by Mehra, Y.P. (2004, p. 7) ["The Output Gap, Expected Future Inflation and Inflation Dynamics: Another Look," The B.E. Journal of Macroeconomics, Berkeley Electronic Press.] that runs the standard HP-filter serially through time using only the data available at a particular point in time for calculating a trend value for that point in time. As a byproduct, a fast sparse-matrix implementation of the standard HP-Filter is included.

Language: Matlab
Date: 2010
References: Add references at CitEc
Citations: View citations in EconPapers (10)

Downloads: (external link)
https://dge.repec.org/codes/meyer-gohde/One_Sided_HP_Filters.zip program code
none

Related works:
This item may be available elsewhere in EconPapers: Search for items with the same title.

Export reference: BibTeX RIS (EndNote, ProCite, RefMan) HTML/Text

Persistent link: https://EconPapers.repec.org/RePEc:dge:qmrbcd:181

Access Statistics for this software item

More software in QM&RBC Codes from Quantitative Macroeconomics & Real Business Cycles
Bibliographic data for series maintained by Christian Zimmermann ().

 
Page updated 2025-03-23
Handle: RePEc:dge:qmrbcd:181