In :%pylab inline from scipy import signal import math pylab.rcParams['figure.figsize'] = (16, 6) pylab.rcParams["font.size"] = "20"
Populating the interactive namespace from numpy and matplotlib
In :wsz=50 # window size
In :def window_overlap(win, title_str): grid(True) title(title_str) plot(win) sig = zeros(wsz*4) overlap = wsz/2 for off in range(0, (2*wsz)+1, overlap): sig[off:off+wsz] += win plot(sig)
In :window_overlap(signal.hamming(wsz, False), 'hamming')
In :window_overlap(signal.hann(wsz, False), 'hann')
In :window_overlap(signal.triang(wsz, False), 'triang')
In [ ]: