[data1,fs]=audioread('airplane.mp3');
t=(1:length(data1))/fs;
figure(1);
plot(t,data1);
xlabel('时间');
ylabel('幅度');
补充说明
1.采样率为每秒内的采样点数,所以采样时间=采样点数/采样频率

本文介绍如何使用Matlab读取音频文件并绘制其波形图,通过实例演示了如何获取音频数据和采样率,计算采样时间,并使用plot函数进行可视化展示。
[data1,fs]=audioread('airplane.mp3');
t=(1:length(data1))/fs;
figure(1);
plot(t,data1);
xlabel('时间');
ylabel('幅度');
补充说明
1.采样率为每秒内的采样点数,所以采样时间=采样点数/采样频率


被折叠的 条评论
为什么被折叠?