Christiano-Fitzgrald filter
[fX,AA]=cffilter(namey,pl,pu,arg1,...,argn)
* namey = a time series, a real (nx1) vector or a string equal to the name of a time series or a (nx1) real vector between quotes.
* pl = minimum period of oscillation of desired component
* pu = maximum period of oscillation of desired component
* (2< = pl<pu<infinity)
* arg1,...,argn = optional arguments that can be the following:
- 'root=0' or 'root=1' whether you want to assume 0 or 1 unit root in time series (default: root = 1);
- 'drift=0' or 'drift=1' whether you want to assume no drift or a time trend in time series (default: drift = 1);
- 'filt=asym' or 'filt=sym' or 'filt=flsym' whether you want to use the asymmetric Filter, the symmetric Filter or the Fixed Length Symmetric Filter (default='asym')
- 'nfix=xx' where xx is the fixed length (useful only for the symmetric filter, that is filt=flsym) (default: nfix=-1).
- 'thet = xx' with xx vector corresponding to the MA representation of x (if root=0) or delta(x) (if root =1)
(default: thet=1)
* cfy = the smoothed filtered series of the same type than y (if y is not a string) or evstr(y) (if y is a string)
load(GROCERDIR+'/macros/grocer/db/cffilter.dat'); [gdp_f,A]=cffilter(gdp,2,8,'root=1','drift=1','asym') // Provides the assymmetric Christiano-Fitzgerald filter for series gdp, with cycles lasting from 2 to 8 quarters, a unit root and a trend. | ![]() | ![]() |