I'm creating a function which takes as input a .fig file and it modifies its properties following a standard that I defined.
I would like to add an option to change the color of the plots according to a color order that I defined. If the figure has only one plot it's easy, I can modify the color property of each Line found with findobj, but I'm stuck with the figures having subplots.
I was thinking to use the ColorOrder option taken from the axes properties but the figure does not 'refresh' with the new colors (I tried also to use refresh( ... ) ).
Another idea I had was to modify the color Line by Line but I'm not able to distinguish to which subplot they belong (in theory every subplot should restart the color order).
Here is an idea of the outcome where on the left there is subplot(121) not yet modified while in subplot(122) there is the plot with the new color order. At the end subplot(121) and subplot(122) should have the same colors.