File Exchange

image thumbnail

Speech Spectrogram

version (2.8 MB) by Kamil Wojcicki
High quality speech spectrogram plot generation routine


Updated 01 Dec 2010

View License

Takes a vector containing audio data samples as an input, computes short-time Fourier transform (STFT) and plots the STFT power spectrum trajectories across time.

Cite As

Kamil Wojcicki (2020). Speech Spectrogram (, MATLAB Central File Exchange. Retrieved .

Comments and Ratings (7)

Naman Gogia

Naman Gogia


Hi, How do you choose the vector of spectrogram limits?


I really like the visual result of your function. I have a question, though:
where does that black dots grid-like superimposed to the spectrograms come from?

Hi Alecsander, you can pass color map as one of the inputs to the myspectrogram method. In the test_myspectrogram.m try, f.e.,

myspectrogram( speech.(method), fs, [22 1], @hamming, 2048, [-59 -1], false, 'hot', false, 'per' );

Alternatively you can specify color map for the current figure after calling the myspectrogram method, e.g.,

myspectrogram( speech.(method), fs );
colormap hot;
%colormap jet;

See also

Very nice and works well.
I'll appreciate if it could support color spectrogram.

MATLAB Release Compatibility
Created with R2010a
Compatible with any release
Platform Compatibility
Windows macOS Linux