filter_hp: Hodrick-Prescot Filter

Description Usage Arguments See Also Examples

View source: R/07-filter.R

Description

Maturing lifecycle

This function computes the cyclical component of the Hodrick-Prescot filter.

Usage

1

Arguments

x

[univariate vector]

Univariate vector, numeric or ts object with only one dimension.

...

Further arguments passed to hpfilter.

See Also

select_lambda

Examples

1
2
3
unemp <- ggplot2::economics$unemploy
unemp_cycle <- filter_hp(unemp, freq = select_lambda("monthly"))
plotx(cbind(unemp, unemp_cycle))

kvasilopoulos/transx documentation built on Jan. 26, 2021, 6:14 p.m.