How to plot two plots in one graph?

How can I plot "Chaotic_Balance(0.02, 9, 18, 1)" and "Chaotic_Balance(0.02, 10, 18, 1)" in one graph and label them like the picture shows below (red and blue line with descriptions)?

댓글 수: 3

VBBV
VBBV 2021년 2월 2일
Use hold on after plot.
Pass Rd as vector
Shuqing Qi
Shuqing Qi 2021년 2월 2일
I used it in a new script, but it seemed not work as well. Why is it?
Mathieu NOE
Mathieu NOE 2021년 2월 2일
hi
it would be more efficient maybe if you could share the code (and the data if needed)

댓글을 달려면 로그인하십시오.

답변 (1개)

Adam Danz
Adam Danz 2021년 2월 2일
편집: Adam Danz 2021년 2월 3일

0 개 추천

Place it just before the i-loop
figure()
hold on
for i = 1:Year
...
end
hold off % optional

카테고리

도움말 센터File Exchange에서 Line Plots에 대해 자세히 알아보기

태그

질문:

2021년 2월 2일

편집:

2021년 2월 3일

Community Treasure Hunt

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

Start Hunting!

Translated by