Learn R Programming

astrochron (version 0.4.3)

bandpass: Bandpass Filter Stratigraphic Series

Description

Bandpass filter stratigraphic series using rectangular, Gaussian or tapered cosine window

Usage

bandpass(dat,padfac=2,flow=NULL,fhigh=NULL,win=0,alpha=3,p=0.25,demean=T,
         detrend=F,addmean=T,output=1,xmin=0,xmax=Nyq,genplot=T,verbose=T)

Arguments

dat
Stratigraphic series for bandpass filtering. First column should be location (e.g., depth), second column should be data value.
padfac
Pad with zeros to (padfac*npts) points, where npts is the original number of data points.
flow
Lowest frequency to bandpass.
fhigh
Highest frequency to bandpass.
win
Window type for bandpass filter: 0 = rectangular , 1= Gaussian, 2= Cosine-tapered window.
alpha
Gaussian window parameter: alpha is 1/stdev, a measure of the width of the Dirichlet kernel. Choose alpha >= 2.5.
p
Cosine-tapered window parameter: p is the percent of the data series tapered (choose 0-1).
demean
Remove mean from data series? (T or F)
detrend
Remove linear trend from data series? (T or F)
addmean
Add mean value to bandpass result? (T or F)
output
Output: (1) filtered series, (2) bandpass filter window.
xmin
Smallest frequency for plotting.
xmax
Largest frequency for plotting.
genplot
Generate summary plots? (T or F)
verbose
Verbose output? (T or F)

Value

  • bandpassed stratigraphic series.

See Also

lowpass, noKernel, noLow, prewhiteAR, prewhiteAR1, and taner

Examples

Run this code
# generate example series with 3 precession terms and noise
ex <- cycles(noisevar=.0004,dt=5)
# bandpass precession terms using cosine-tapered window 
res_ex <- bandpass(ex,flow=0.038,fhigh=0.057,win=2,p=.4)

Run the code above in your browser using DataLab