how to plot results ?

1 次查看(过去 30 天)
Aniket
Aniket 2013-3-12
Hello,
I am running for loop and saving results from error to e1{1}.... for each iteration.
but i want to plot the results. how should i do this ? is this correct method of saving results?
*******************************
for p=1:3
for q = 1:50
v = ['w', num2str(q),'(2,end)'];
w(q) = eval(v);
end
sim('with50osc.mdl')
e2{1}=error;
e3{2}=error;
e4{3}=error;
end
****************************************

采纳的回答

Walter Roberson
Walter Roberson 2013-3-12
  7 个评论
Walter Roberson
Walter Roberson 2013-3-12
colors = {'r', 'g', 'c', 'b'}; %color for traces
for K = 1 : length(e)
plot(e{K}(:,1), e{K}(:,2), colors{K} );
hold on
end
Aniket
Aniket 2013-3-12
Thanks for this its working

请先登录,再进行评论。

更多回答(0 个)

类别

Help CenterFile Exchange 中查找有关 Annotations 的更多信息

标签

Community Treasure Hunt

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

Start Hunting!

Translated by