How to plot multiple plots repeatedly from a loop?
이전 댓글 표시
I have a code which has a 'for' loop running three times. For each iteration, the script computes the value of three functions, let F1, F2 and F3. I have:
figure()
for k=1:1:3
some variable computations;
F1(k)=Value1;
F2(k)=Value2;
F3(k)=Value3;
plot(F1,F2);
hold on
end
This script plots F1 against F2 on the same plot for 3 levels of k. Thats what I need. But now I wish to plot F2 with F3 also from the same script. This needs to be a separate plot, but should also consist of all three plots for 3 levels of k. If I add a new 'figure' before writing plot (F2, F3), it will create 3 plots for 3 levels of k, while I need all of them on one plot. Please guide.
채택된 답변
추가 답변 (0개)
카테고리
도움말 센터 및 File Exchange에서 2-D and 3-D Plots에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!