I've had a go and come up with the following simplified example:
Array1 =[0 0 0 0 0 0; 0 1 0 2 0 6; 4 0 5 5 0 9; 0 10 7 0 8 0];
Array2 =[0 0 0 0 0 0; 0 1 0 2 0 3; 4 0 5 5 0 6; 0 7 0 8 9 0];
mymap = [0 0 0; 0.6 1 0.2;1 1 0;0.6 0.2 1; 1 0.6 0.2;1 0 1;0.2 1 0.6;0 1 0;1 0 0;0.2 0.6 1;0 0 1];
colormap(mymap);
imagesc (Array1);
imagesc (Array2);
At the moment, the value of 7 in Array1 is appearing as green and the value of 7 in Array 2 is appearing as red. I want 7 to always be plotted as green! Same applies to the other colors. I want them to be consistent with the corresponding value.