How to plot multiple audio files horizontally in MATLAB

 採用された回答

Chunru
Chunru 2021 年 11 月 10 日

0 投票

n = 1000;
t = (0:n-1)'*.0001;
x = randn(n, 6); % 1000 samples 6 channels
y = 0.2*x + (1:6); % scale the x by 0.2, add offset for each channel
plot(t, y)
xlabel('t (s)');
set(gca, 'YTick', (1:6), 'YTickLabel', "ch"+(1:6))

5 件のコメント

Deepu S S
Deepu S S 2021 年 11 月 10 日
@Chunru thank you
i want to plot audio files like this,is it possible ....? ??
Deepu S S
Deepu S S 2021 年 11 月 10 日
if i browse one directory(audio files), then i want to plot all the audio files from it like above figure
Chunru
Chunru 2021 年 11 月 10 日
You can store the data from files as a matrix. Different files may have different length. You may need to append 0 for short files in that case.
Deepu S S
Deepu S S 2021 年 11 月 10 日
how to store the data from files as matrix?
Rik
Rik 2021 年 11 月 10 日
doc audioread

サインインしてコメントする。

その他の回答 (0 件)

質問済み:

2021 年 11 月 10 日

コメント済み:

Rik
2021 年 11 月 10 日

Community Treasure Hunt

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

Start Hunting!

Translated by