Hi..I would like to plot a 2D plot for 15 to 20 data points with 15 to 20 different color ..how can I do it?
1 回表示 (過去 30 日間)
古いコメントを表示
Harini pushparaj
2017 年 11 月 11 日
回答済み: Kaushik Lakshminarasimhan
2017 年 11 月 11 日
Hi I want to know how to plot a graph with different color.If you see in the file i have attached ,I have already plotted with 7 colors but,I want to plot with 20 different data with 20 different color.Kindly help me on this.Thank you in advance !!!
0 件のコメント
採用された回答
Kaushik Lakshminarasimhan
2017 年 11 月 11 日
Nswarms = 20;
cmap = colormap(jet(Nswarms));
for i=1:Nswarms
hold on; plot(tictoc(i),Jopt(i),'*','Color',cmap(i,:));
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!