s*t
3 楼
matlab by default use different colors for different lines if you
plot them in one plot function.
if you want to use your own colors, you can define a color matrix (Nx3)
in rgb colors. each time take a row from that matrix and plot using that
color by plot(x, y, 'Color', colors(ii,:)).
you can also get the default line colors used by matlab by
colors = colormap('Lines')
【在 h***q 的大作中提到】
: 在一幅图里面画了很多条曲线,如何自动为他们分配颜色以示区别?
plot them in one plot function.
if you want to use your own colors, you can define a color matrix (Nx3)
in rgb colors. each time take a row from that matrix and plot using that
color by plot(x, y, 'Color', colors(ii,:)).
you can also get the default line colors used by matlab by
colors = colormap('Lines')
【在 h***q 的大作中提到】
: 在一幅图里面画了很多条曲线,如何自动为他们分配颜色以示区别?
h*q
4 楼
Great idea!
【在 s***t 的大作中提到】
: matlab by default use different colors for different lines if you
: plot them in one plot function.
: if you want to use your own colors, you can define a color matrix (Nx3)
: in rgb colors. each time take a row from that matrix and plot using that
: color by plot(x, y, 'Color', colors(ii,:)).
: you can also get the default line colors used by matlab by
: colors = colormap('Lines')
【在 s***t 的大作中提到】
: matlab by default use different colors for different lines if you
: plot them in one plot function.
: if you want to use your own colors, you can define a color matrix (Nx3)
: in rgb colors. each time take a row from that matrix and plot using that
: color by plot(x, y, 'Color', colors(ii,:)).
: you can also get the default line colors used by matlab by
: colors = colormap('Lines')
s*o
5 楼
我试了一下,同一幅图中最多自动支持7种不同的颜色,如果超过7条曲线,就自动重复
默认的7种颜色。这是怎么回事呢?
【在 s***t 的大作中提到】
: matlab by default use different colors for different lines if you
: plot them in one plot function.
: if you want to use your own colors, you can define a color matrix (Nx3)
: in rgb colors. each time take a row from that matrix and plot using that
: color by plot(x, y, 'Color', colors(ii,:)).
: you can also get the default line colors used by matlab by
: colors = colormap('Lines')
默认的7种颜色。这是怎么回事呢?
【在 s***t 的大作中提到】
: matlab by default use different colors for different lines if you
: plot them in one plot function.
: if you want to use your own colors, you can define a color matrix (Nx3)
: in rgb colors. each time take a row from that matrix and plot using that
: color by plot(x, y, 'Color', colors(ii,:)).
: you can also get the default line colors used by matlab by
: colors = colormap('Lines')
相关阅读
请教一个fortran 90编程的问题求教finite size lyapunov exponent的计算问题,谢谢!Matlab 中的 一个3D 画图的问题about using GAMS/Cplex to solve a MIP problem已知SVD,如何求nullspace?再问个random number的问题 讨论一下GA算法matlab输出问题matlab print jpg figure axes missing请问Matlab的输出问个关于matlab 编译exe的问题还有人吗。。。问一个算术问题请教哪可以下载ssh secure data transfer client请教:关于Matlab画图能不能用量子的方法算磁感啊 (转载)what background need to undersatnd SDE.朱伯芳编的有限单元法原理与应用-谁要?lapack++ and blitz++请教Fortran有人用OpenDx软件么?