melfilterbank | R Documentation |
This functions returns graphically and numerically the Mel-filters used to compute MFCC.
melfilterbank(f = 44100, wl = 1024,
minfreq = 0, maxfreq = f/2, m = 20,
palette, alpha = 0.5, plot = FALSE)
f |
sammpling frequency (in Hz). |
wl |
the Fourier window length (in number of samples). |
minfreq |
the minimum (or lower) frequency of the filter bank (in Hz). |
maxfreq |
the maximum (or upper) frequency of the filter bank (in Hz). |
m |
the total number of filters. |
palette |
an optional colour palette if |
alpha |
alpha-transparency when a colour palette is used. |
plot |
if |
A list of 3 items:
central.freq |
the kHz central frequencies of the filters, |
freq |
the kHz frequency scale, |
amp |
the amplitude of the filters, scaled between 0 and 1. |
These triangular filters are used for computing MFCCs.
Jerome Sueur
Sharan RV & Moir TJ (2016) Applications and advancements in automatic sound recognition. Neurocomputing.
mel
, gammatone
## default values
melfilterbank(plot=TRUE)
## with color surfaces
melfilterbank(palette=cm.colors, plot=TRUE)
## values changed
res <- melfilterbank(f=16000, wl=512, minfreq=300, plot=TRUE)
## plot the 1st filter only
plot(res$freq, res$amp[,1], type="l", xlab="Frequency (kHz)", ylab="Amplitude")
## plot the last filter only
plot(res$freq, res$amp[,ncol(res$amp)], type="l", xlab="Frequency (kHz)", ylab="Amplitude")
## get the kHz central frequencies of the succesive filters
res$central.freq
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.