.modulationSpectrum | R Documentation |
Internal soundgen function.
.modulationSpectrum(
audio,
amRes = 5,
maxDur = 5,
logSpec = FALSE,
windowLength = 15,
step = NULL,
overlap = 80,
wn = "hanning",
zp = 0,
power = 1,
normalize = TRUE,
roughRange = c(30, 150),
amRange = c(10, 200),
returnMS = TRUE,
returnComplex = FALSE,
plot = TRUE,
savePlots = NULL,
logWarpX = NULL,
logWarpY = NULL,
quantiles = c(0.5, 0.8, 0.9),
kernelSize = 5,
kernelSD = 0.5,
colorTheme = c("bw", "seewave", "heat.colors", "...")[1],
col = NULL,
main = NULL,
xlab = "Hz",
ylab = "1/KHz",
xlim = NULL,
ylim = NULL,
width = 900,
height = 500,
units = "px",
res = NA,
...
)
audio |
a list returned by |
amRes |
target resolution of amplitude modulation, Hz. If |
maxDur |
sounds longer than |
logSpec |
if TRUE, the spectrogram is log-transformed prior to taking 2D FFT |
windowLength |
length of FFT window, ms |
step |
you can override |
overlap |
overlap between successive FFT frames, % |
wn |
window type accepted by |
zp |
window length after zero padding, points |
power |
raise modulation spectrum to this power (eg power = 2 for ^2, or "power spectrum") |
normalize |
if TRUE, the modulation spectrum of each analyzed fragment
|
roughRange |
the range of temporal modulation frequencies that constitute the "roughness" zone, Hz |
amRange |
the range of temporal modulation frequencies that we are interested in as "amplitude modulation" (AM), Hz |
returnMS |
if FALSE, only roughness is returned (much faster) |
returnComplex |
if TRUE, returns a complex modulation spectrum (without normalization and warping) |
plot |
if TRUE, plots the modulation spectrum of each sound |
savePlots |
if a valid path is specified, a plot is saved in this folder (defaults to NA) |
logWarpX, logWarpY |
numeric vector of length 2: c(sigma, base) of
pseudolog-warping the modulation spectrum, as in
|
quantiles |
labeled contour values, % (e.g., "50" marks regions that contain 50% of the sum total of the entire modulation spectrum) |
kernelSize |
the size of Gaussian kernel used for smoothing (1 = no smoothing) |
kernelSD |
the SD of Gaussian kernel used for smoothing, relative to its size |
colorTheme |
black and white ('bw'), as in seewave package ('seewave'),
or any palette from |
col |
actual colors, eg rev(rainbow(100)) - see ?hcl.colors for colors in base R (overrides colorTheme) |
xlab, ylab, main, xlim, ylim |
graphical parameters |
width, height, units, res |
parameters passed to
|
... |
other graphical parameters passed on to |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.