bandstop_filter {fMRItools} | R Documentation |
Bandstop filter
Description
Filter out frequencies within a given range using a Chebyshev Type II
stopband. Essentially a convenience wrapper for the
cheby2
function.
Usage
bandstop_filter(X, TR, f1, f2, Rs = 20)
Arguments
X |
A numeric matrix, with each column being a timeseries to apply
the stopband filter. For fMRI data, |
TR |
The time step between adjacent rows of |
f1 , f2 |
The frequency limits for the filter, in Hz. |
Rs |
The amount of attenuation of the stopband ripple, in dB |
Value
The filtered data
Examples
if (requireNamespace("gsignal", quietly=TRUE)) {
n_voxels = 1e4
n_timepoints = 100
X = cbind(arima.sim(n=100, list(ar=.6)), arima.sim(n=100, list(ar=.6)))
Y = bandstop_filter(X, .72, .31, .43)
}
[Package fMRItools version 0.4.7 Index]