how to produce multtiple stacked plots with different colors in a for loop?
2 ビュー (過去 30 日間)
古いコメントを表示
Zeynab Mousavikhamene
2019 年 10 月 25 日
編集済み: Zeynab Mousavikhamene
2019 年 10 月 25 日
I am producing multiple plots in a for loop in one axis. Any idea to produce different colors for each plot? It will be ~60 plots stacked on each other.
Beacuse plots are stacked in a for loop I cant give individual color as usual.
採用された回答
Daniel M
2019 年 10 月 25 日
t = 0:0.001:1;
figure
col = jet(60);
for k = 1:60
x = sin(2*pi*5*t + k/60);
plot(t,x,'-','Color',col(k,:));
hold on
end
0 件のコメント
その他の回答 (0 件)
参考
カテゴリ
Help Center および File Exchange で Orange についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!