MATLAB: How to read an audio file in matlab and analyze this file graphically

.mat file.mp4audio filematlab datamp3video file

Assalam-o-Alaikum sir!
I want to analyze the audio file graphically by using matlab. The first thing is that I've to load it in matlab then plot it. After all that, I also have to save this as matlab data (.mat file).
I don't know how I can do that. Please help me.

Best Answer

Use the audioread (link) function to read the file, then the save (link) function to save it as a ‘.mat’ file.
[y,Fs] = audioread(filename);
save('my_sound_file.mat', 'y', 'Fs');
See the plot, linspace (to create your time vector) and related functions to process your sound data.
Related Question