Octave graphic add-on, Octplot



česky

1.8 Function specgram



User defined function: [s [, f[, t]]] = specgram(x[,n [, Fs[, window[, overlap]]]])


We can use this function to compute dependent-time frequency analyses. It computes displayed discrete time of Fourier transformation of signal. Spectogram is value in this function.

Examples:
[x,y]=meshgrid(0:1:5,0:1:5);
x = chirp([0:0.001:2],0,2,500); # frekvence od 0-500 po 2 sekundách.;
Fs=1000; # vzorkování každé 0.001 sekundy, takže rychlost je 1 kHz ;
step=ceil(20*Fs/1000); # jeden spektrální dílek každých 20 ms
window=ceil(100*Fs/1000); # 100 ms data window
specgram(x, 2^nextpow2(window), Fs, window, window-step);





<<< 1.7 Pseudo-picture - function pcolor 1.9 Save figure to a file - function print >>>

© 2008 David Prokop