Create a gammatoneFilterBank object. Call freqz to get the complex frequency response, H, of the filter bank and a vector of frequencies, f, at which the response is calculated. Plot the magnitude frequency response of the filter bank.

To get the frequency response of a subset of filters in the filter bank, specify the second argument as a row vector of indices between one and the number of filters in the filter bank. Get the frequency response of the 10th filter in the filter bank and plot the magnitude frequency response.

To specify the number of FFT points used to compute the frequency response, use the NFFT name-value pair. Specify that the frequency response is calculated using a 128-point FFT. Plot the magnitude frequency response.

To visualize the magnitude frequency response only, call freqz without any output arguments. Plot the magnitude frequency response, in dB, of filters 20, 21, and 22 using a 1024-point DFT.

Create an octaveFilterBank object. Call freqz to get the complex frequency response, H, of the filter bank and a vector of frequencies, f, at which the response is calculated. Plot the magnitude frequency response in dB.

To get the frequency response of a subset of filters in the filter bank, specify the second argument as a row vector of indices between one and the number of filters in the filter bank. Get the frequency response of the 5th filter in the filter bank and plot the magnitude frequency response in dB.

To specify the number of FFT points used to compute the frequency response, use the NFFT name-value pair. Specify that the frequency response is calculated using a 8192-point FFT. Plot the magnitude frequency response in dB.

To visualize the magnitude frequency response only, call freqz without any output arguments. Plot the magnitude frequency response, in dB, of filters 4, 5, and 6 using a 1024-point DFT.

ind — Indices of filters to calculate frequency responses from 1:N (default) | row vector of integers with values in the range [1, N]

Indices of filters to calculate frequency responses from, specified as a row vector
of integers with values in the range [1, N]. N is
the total number of filters designed by obj.

Name-Value Pair Arguments

Specify optional
comma-separated pairs of Name,Value arguments. Name is
the argument name and Value is the corresponding value.
Name must appear inside quotes. You can specify several name and value
pair arguments in any order as
Name1,Value1,...,NameN,ValueN.

Example: 'NFFT',2048

'NFFT' — Number of DFT bins 8192 (default) | positive integer

Number of DFT bins, specified as a positive integer.

H — Complex frequency response of each filter matrix

Complex frequency response of each filter, returned as an
M-by-N matrix. M is the
number of DFT bins, specified by NFFT. N is the
number of filters, which is either length(ind)
or, if ind is not specified, the total number of filters in the
filter bank.

Data Types: double

f — Frequencies at which response is computed (Hz) column vector

Frequencies at which the response is computed in Hz, returned as a column
vector.

You can also select a web site from the following list:

How to Get Best Site Performance

Select the China site (in Chinese or English) for best site performance. Other MathWorks country sites are not optimized for visits from your location.