savgolay: Perform Savitzgy-Golay smoothing on Time Series Data

Description Usage Arguments Details Value Examples

View source: R/smoother3.R

Description

Use this function to smooth your time series data using local polynomial regression, as first pouplarised by Savitzky and Golay (1964).

Usage

1
savgolay(input, width = 4, degree = 2)

Arguments

input

Input Vector with Time Series Data

width

Width of the filter (to each side of the centre)

degree

Highest degree polynomial

Details

For an overview of the package capabilities, click here rpatrec. See the report for detailed references

Value

Vector containing smoothed time series data.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
savgolay(input=c(1,6,2,46,23,1,2,13,23,35,23,-2,3,23))
## Not run: 
#create a standard HS pattern:
a <- generator()
#add noise to this patterns
b <- noise(a,'white',10)
#smooth to regain the signal
c <- savgolay(b,8,2)

## End(Not run)

rpatrec documentation built on May 1, 2019, 11:17 p.m.