Learn R Programming

soundgen (version 1.7.0)

getMelSpec: Mel-transformed spectrum

Description

Internal soundgen function

Usage

getMelSpec(
  s,
  samplingRate = NULL,
  windowLength = 40,
  overlap = 50,
  step = NULL,
  dynamicRange = 80,
  maxFreq = NULL,
  plot = FALSE
)

Arguments

s

input sound (path to a .wav file or numeric vector)

samplingRate

sampling rate of target (only needed if target is a numeric vector, rather than a .wav file)

windowLength

length of FFT window, ms

overlap

overlap between successive FFT frames, %

step

you can override overlap by specifying FFT step, ms

dynamicRange

parts of the spectra quieter than -dynamicRange dB are not compared

maxFreq

parts of the spectra above maxFreq Hz are not compared

plot

if TRUE, plots the spectrum

Details

Takes a .wav file or a waveform as numeric vector + samplingRate and returns mel-transformed spectrum (auditory spectrum). Calls melfcc. See matchPars.