fftresample: Upsample timeseries

Description Usage Arguments Value Examples

View source: R/fftresample.R

Description

Upsample a timeseries using FFT

Usage

1
fftresample(s, nfac = 2, pct = 0.025, deltat = 1)

Arguments

s

timeseries (as a ts object or vector of samples)

nfac

upsampling factor (integer greater than 1)

pct

percent length of timeseries used for cosine-squared taper of ends. This reduces edge effects, but is lossy.

deltat

sampling interval; used only if s is not a ts object

Value

resampled timeseries.

Examples

1
2
3
4
s <- ts( sin( 2 * pi * 1:100 / 20 ), deltat = 1 )
us <- fftresample( s, nfac = 10 )
plot( s, type = "l" )
lines( us, col = "red" )

jrevenaugh/TSAUMN documentation built on Nov. 8, 2019, 2:20 p.m.