Learn R Programming

seewave (version 1.5.5)

addsilw: Add or insert a silence section

Description

Add or insert a silence section to a time wave.

Usage

addsilw(wave, f, at = "end", choose = FALSE, d = NULL,
plot = FALSE, Sample = FALSE,...)

Arguments

wave
a vector, a matrix (first column), an object of class ts, Sample (left channel), or Wave (left channel).
f
sampling frequency of wave (in Hz). Does not need to be specified if wave is an object of class ts, Sample, or Wave<
at
position where to add the silence section (in s). Can be also specified as "start", "middle" or "end".
choose
logical, if TRUE the point where silence will be added into wave2 (=at) can be graphically chosen with a cursor.
d
duration of the silence section to add (in s).
plot
logical, if TRUE returns an oscillographic plot of wave with the new silence section (by default TRUE).
Sample
if TRUE and plot is FALSE returns an object of class Sample
...
other oscillo graphical parameters.

Value

  • If plot is FALSE, a new wave is returned as a one-column matrix or as a Sample object if Sample is TRUE.

See Also

oscillo, cutw,deletew, fadew,pastew, mutew,revw, zapsilw

Examples

Run this code
data(tico)
addsilw(tico,f=22050,d=0.2)
addsilw(tico,f=22050,at="end",d=0.5)
addsilw(tico,f=22050,at=0.33,d=0.46)

Run the code above in your browser using DataLab