Can't plot spectrum of WAV file in SPTool

2 views (last 30 days)
Stan Shear
Stan Shear on 11 Mar 2013
I'm very new to Matlab, and just started working through the tutorials to get into it. My interest is studying Audio files. I would like to plot the FFT of a 20 second WAV file using SPTool. (I know this is a long signal, but am just using it as an example at the moment, and trying to compare it with other signal analysis software that I'm using). I can import the file into the "Signals" group using audioread and audiowrite as a .mat file, where it comes up as a Matrix, not Vector (as with the built-in examples of Chirp, Mat and Train), but when I try and import it as a Spectrum, and click View,the "Create" button under the Spectra group remains dimmed. I'm not sure what to enter under PSD and Freq Vector, and at the best, get the error message "Input spectral data must be real an non-negative' even though the Preferences setting is [0,Fs/2]. Please help. Thanks Stan

Answers (0)

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!