Matlab Plot with color adjustment

Does anyone know which command or method to capture with different colors besides a given color, that is, b, g, r, c, m, y, k? I would rather use my own color settings instead of them ....

Greetings

+5
source share
3 answers

Use a property Colorwith a triple ColorSpec:

plot(x, y, 'Color', [0.5, 1.0, 0.0], 'LineStyle', '--')

Here the vector contains the RGB values ​​between 0.0and 1.0. In Lineseries and ColorSpec , the documentation entry has more information about this.

+12
source

From matlab docs:

ColorOrder: m-by-3 RGB value matrix

, . , plot3 . 3, ColorOrder, . ColorOrder, , :

get (gca, 'ColorOrder') , NextPlot ( ), , plot resetColorOrder, . MATLAB ColorOrder, , NextPlot . ColorOrder.

, , :

figure();
axis();
set(gca, 'colororder', <color matrix>, 'nextplot', 'replacechildren');
plot(x,y);
0

All Articles