필터 지우기
필터 지우기

how to add plot values for many iteration

조회 수: 1 (최근 30일)
zamri
zamri 2014년 6월 5일
편집: zamri 2014년 6월 5일
Hi all, i wonder if anyone could help me. I have this codes where it plots a function from x-axis values from 1 to 500. The graph has this x and y axis.
I repeat this plot for many locations (coordinate), I was able to get all the plot for 32x4 coordinates.
However I want to add all this plots (the y-axis values) and just have one final plot for all the coordinates (in the codes the coordinates are represented by w and g letters). It is like I add the y-values every time for all the coordinates. How can I do that?
for w=3:2:9
for g=1:32
z=(w-2)*dz0; % 4 points laterally
theta=g*dtheta0; % 32 points circumferentially
%step from 1 to 500
for fi=1:500
.........
................
pressurey(fi)=(si1)*small_ay;
%plot
SPL(fi)=abs(pressurey(fi));
end
freq=1:500;
plot(freq,SPL,'b')
hold on
end
end

답변 (0개)

카테고리

Help CenterFile Exchange에서 Line Plots에 대해 자세히 알아보기

태그

Community Treasure Hunt

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

Start Hunting!

Translated by