次のコードがある場合:
for t=1:length(s) % s is a struct with over 1000 entries
if s(t).BOX==0
a(t,:)=0;
elseif s(t).BOX==1
a(t,:)=100;
end
if s(t).BOX==2
b(t,:)=150;
elseif s(t).BOX==3
b(t,:)=170;
end
.
.
.
end
plot(a)
plot(b)
plot(c)
私が達成したいこと:
for n=1:length(s)
Plot the data point of a(n) at t=0, t=1, t=2
then
Plot the data point of b(n) at t=3, t=4, t=5
.
.
.
etc
したがって、基本的に、各データ ポイントはt
、次のポイントに移動する前に の 3 つの値でプロットされます。
どうすればそれを達成できますか?
編集
このようなもの :