Learn R Programming

itsmr (version 1.1)

smooth.rank: Apply a spectral filter

Description

Apply a spectral filter

Usage

smooth.rank(x, k)

Arguments

x
Data vector
k
Number of frequencies

Value

  • Returns a vector the same length as x.

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