lowpass: Low pass filter a signal

lowpassR Documentation

Low pass filter a signal

Description

Low pass filters a signal using a cascaded butterworth filters.

Usage

lowpass(sound, cutoff = 0.5, order = 6, n_passes = 4)

Arguments

sound

A numeric vector containing the signal to be filtered.

order

The order of the filter to be used.

n_passes

The number of times the filter is applied to the signal.

r

The cutoff frequency of the filter where r = cutoff/Nyquist frequency (Nyquist=fs/2).

Value

A numeric vector containing the filtered signal.

Author(s)

Santiago Barreda <sbarreda@ucdavis.edu>

Examples

## Not run: 
x = rnorm(1000)
filtered_x = lowpass (x, 0.5)
phonTools::spectralslice (x, ylim = c(-200,20), fs=1, col=4)
phonTools::spectralslice (filtered_x, ylim = c(-200,20), add = TRUE, col = 2)
abline (v=0.25)

## End(Not run)

santiagobarreda/phonTools documentation built on March 4, 2024, 11:13 p.m.