line color in figure
3 ビュー (過去 30 日間)
古いコメントを表示
回答 (1 件)
Stephen23
2017 年 1 月 30 日
編集済み: Stephen23
2017 年 1 月 30 日
If you plot all of the lines at once then they will automatically be colored using the axes ColorOrder:
N = 16;
A = linspace(0,pi,N);
X = cos(A);
Y = sin(A);
X(2,:) = 0;
Y(2,:) = 0;
plot(X,Y)
axis equal

The documentation explains how the ColorOrder can be changed:
0 件のコメント
参考
カテゴリ
Help Center および File Exchange で Colormaps についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!