lsevier, pp 593-637. .. [4] Wikipedia, "Window function", http://en.wikipedia.org/wiki/Window_function Examples -------- Plot the window >>> import numpy as np >>> from scipy.signal.windows import lanczos >>> from scipy.fft import fft, fftshift >>> import matplotlib.pyplot as plt >>> fig, ax = plt.subplots(1) >>> window = lanczos(51) >>> ax.plot(window) >>> ax.set_title("Lanczos window") >>> ax.set_ylabel("Amplitude") >>> ax.set_xlabel("Sample") >>> fig.tight_layout() >>> plt.show() and its frequency response: >>> fig, ax = plt.subplots(1) >>> A = fft(window, 2048) / (len(window)/2.0) >>> freq = np.linspace(-0.5, 0.5, len(A)) >>> response = 20 * np.log10(np.abs(fftshift(A / abs(A).max()))) >>> ax.plot(freq, response) >>> ax.set_xlim(-0.5, 0.5) >>> ax.set_ylim(-120, 0) >>> ax.set_title("Frequency response of the lanczos window") >>> ax.set_ylabel("Normalized magnitude [dB]") >>> ax.set_xlabel("Normalized frequency [cycles per sample]") >>> fig.tight_layout() >>> plt.show() c