Generic function to cut off silence or low noise at the beginning and/or at the end of an object of class Wave
or class WaveMC
.
noSilence(object, zero = 0, level = 0, where = c("both", "start", "end"))
An object of class Wave
or WaveMC
.
Object of class Wave
or class WaveMC
.
The zero level (default: 0) at which ideal cut points are determined (see Details).
A typical alternative would be 127 for 8 bit Wave
or WaveMC
objects.
If zero = NA
, the mean of the left Wave channel (for Wave
, resp. the mean of the first channel for WaveMC
) is taken as zero level.
Values in the interval between zero
and zero - level
/zero + level
are considered as silence.
One of "both"
(default), "start"
, or "end"
indicating at where
to prepare the Wave
or WaveMC
object for concatenation.
Uwe Ligges ligges@statistik.tu-dortmund.de, Sarah Schnackenberg, based on code from Matthias Heymann's former package ‘sound’.
Silcence is removed at the locations given by where
of the Wave
or WaveMC
object,
where silence is defined such that (in both channels if stereo, in all channels if multichannel for WaveMC
) all values are in
the interval between zero - level
and zero + level
.
All values before (or after, respectively) the first non-silent value are removed from the object.
silence
, Wave-class, Wave
, WaveMC-class, WaveMC
, extractWave