弱弱的问,关于plot函数的应用
figure
hold on
[JU]=1:1:10
[U]=1:1:10
for i=1:1:10
if JU(i)<=5
U(i)=20;
else
a=func(JU(i))
U(i)=a;
end
end
plot(JU,U,'r')
hold off
提示错误:??? Attempt to execute SCRIPT plot as a function.
Error in ==> JUBUxian at 24
plot(JU,U,'r')
为什么啊?