L1 Filtering

Use this forum for posting example programs or short bits of sample code.
TomDoan
Posts: 7814
Joined: Wed Nov 01, 2006 4:36 pm

L1 Filtering

Unread post by TomDoan »

This does an example from Kim, Koh, Boyd, Gorinevsky(2009), "L1 Filtering", SIAM Review, vol 51, pp 339-360. The L1 filter is a piecewise linear filter similar to the H-P filter. An exact solution for the problem requires a specialized set of optimization software, but it can be very closely approximated with "off-the-shelf" iterated Kalman smoothing as is done here.

One problem (as noted in the comments) with the L1 filter as described in the paper is that the tuning parameter lambda is scale-dependent because one of the terms in the optimand is squared and one is absolute value (unlike the H-P filter, where both are squared). This is set to use a tuning parameter which is scale-independent.
l1trend.rpf
Program file
(2.2 KiB) Downloaded 900 times
l1trend.csv
Data file
(116.32 KiB) Downloaded 956 times
Post Reply