Learn R Programming

itsmr (version 1.9)

smooth.rank: Apply a spectral filter

Description

Apply a spectral filter

Usage

smooth.rank(x, k)

Value

Returns a vector the same length as x.

Arguments

x

Time series data

k

Number of frequencies

Details

Passes the mean and the k frequencies with the highest amplitude. The remainder of the spectrum is filtered out.

Examples

Run this code
y = smooth.rank(deaths,2)
plotc(deaths,y)

Run the code above in your browser using DataLab