# Is it possible for Matlab to read and decode an mp3 file?

I have run the following Matlab code and I got a signal as shown in the Figure below.

[y, fs] = audioread(mp3file);
y1 = y(:,1);
y2 = y(:,2);
dt = 1/fs;
t1 = 0:dt:(length(y1)*dt)-dt;
t2 = 0:dt:(length(y2)*dt)-dt;
plot(t1,y1);
hold on
plot(t2,y2);


Is this a signal generate from a raw mp3 file or it is generated from a Matlab-decoded-mp3 file (which means Matlab has internally decoded the mp3 file)?

The latter. $$audioread()$$ reads the raw MP3 bit stream, decodes it, and returns the decoded audio data as PCM data. If you want the raw bit stream use $$fread()$$ instead.