How to add all the curves in a single figure?

1 回表示 (過去 30 日間)
Nisar Ahmed
Nisar Ahmed 2020 年 9 月 25 日
コメント済み: KSSV 2020 年 9 月 25 日
Hello,
These are the Rpp curves plotted against time for different incident angles just like:
figure(4),
subplot(1,5,1);
plot(Out(:,1),time);
xlabel('Rpp')
ylabel('Time (ms)')
set(gca, 'ydir', 'reverse');
subplot(1,5,2);
plot(Out(:,10),time);
set(gca, 'ydir', 'reverse');
subplot(1,5,3);
plot(Out(:,20),time);
set(gca, 'ydir', 'reverse');
here Out is Rpp and (:,1) represents angle. I want to plott all the plots in one figure rather by using subplots... How I can change the figure code to get all these on figure?
  1 件のコメント
Nisar Ahmed
Nisar Ahmed 2020 年 9 月 25 日
Figure is attached to the question.

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

採用された回答

KSSV
KSSV 2020 年 9 月 25 日
編集済み: KSSV 2020 年 9 月 25 日
figure(4)
hold on
plot(Out(:,1),time);
plot(Out(:,10),time);
plot(Out(:,20),time);
set(gca, 'ydir', 'reverse');
xlabel('Rpp')
ylabel('Time (ms)')
OR
figure(4)
plot(Out(:,[1 10 20]),time);
set(gca, 'ydir', 'reverse');
xlabel('Rpp')
ylabel('Time (ms)')
  2 件のコメント
Nisar Ahmed
Nisar Ahmed 2020 年 9 月 25 日
THANKS KSSV but all the curves have same values and therefore will overlap on each other. therefore, I need to plot them on separate paths corresponding to each angle.
KSSV
KSSV 2020 年 9 月 25 日
Add some number to xdata so that it will be shifted.

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

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeTwo y-axis についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by