Learn R Programming

soundgen (version 2.3.0)

.getRMS: RMS amplitude per sound

Description

Internal soundgen function called by getRMS.

Usage

.getRMS(
  audio,
  windowLength = 50,
  step = NULL,
  overlap = 75,
  killDC = FALSE,
  normalize = TRUE,
  windowDC = 200,
  plot = TRUE,
  main = NULL,
  xlab = "",
  ylab = "",
  type = "b",
  col = "green",
  lwd = 2,
  width = 900,
  height = 500,
  units = "px",
  res = NA,
  ...
)

Arguments

audio

a list returned by readAudio

windowLength

length of FFT window, ms

step

you can override overlap by specifying FFT step, ms (NB: because digital audio is sampled at discrete time intervals of 1/samplingRate, the actual step and thus the time stamps of STFT frames may be slightly different, eg 24.98866 instead of 25.0 ms)

overlap

overlap between successive FFT frames, %

killDC

if TRUE, removed DC offset (see also flatEnv)

normalize

if TRUE, the RMS amplitude is returned as proportion of the maximum possible amplitude as given by scale

windowDC

the window for calculating DC offset, ms

plot

if TRUE, plot a contour of RMS amplitude

main

graphical parameters for plotting

xlab

general graphical parameters

ylab

general graphical parameters

type

graphical parameters pertaining to the RMS envelope

col

graphical parameters pertaining to the RMS envelope

lwd

graphical parameters pertaining to the RMS envelope

width

graphical parameters for saving plots passed to png

height

graphical parameters for saving plots passed to png

units

graphical parameters for saving plots passed to png

res

graphical parameters for saving plots passed to png

...

other graphical parameters