My matlab is using same color in drawing multiple lines in figure

11 visualizaciones (últimos 30 días)
2014a version
figure hold plot(a,b) plot(c,d)
The colors of two lines are same pure blue.
Why doesn't color change? How can I fix this issue?
Thanks

Respuesta aceptada

Archita P
Archita P el 20 de Mzo. de 2017
There was a major Graphics update from MATLAB R2014a TO R2014b. In R2014a and earlier, the "hold on" command does not retain the current color so new plots added to the axes start from the beginning of the color order. Visually, this means that new plots use the same initial color. Starting in R2014b, the "hold on" command retains the current color so that new plots added to the axes use the next colors in the color order.
Plotting multiple lines with "hold on" uses the next color in the color order instead of starting from the first color with each plotting command starting from MATLAB R2104b.
You can refer to the following link for more information (under topic "Graphics->Compatibility considerations for graphics changes")-
https://www.mathworks.com/help/matlab/release-notes.html?rntext=&startrelease=R2014a&endrelease=R2014b&groupby=release&sortby=descending&searchHighlight=

Más respuestas (0)

Categorías

Más información sobre Graphics Object Properties en Help Center y File Exchange.

Etiquetas

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by