How to match colors of an extracted contour with the colors of the main figure?
Show older comments
I extracted the region for activity, xi = linspace(58, 115) and l=(1.24787e-06, 2.42592e-06) from the figure attached, which is represened by the red and yellow colors. Please how can I set colormap colors for the extracted figure to be the same colors (red and yellow) as the figure main(attached figure)? The code for the main plot is given below:

figure;
[C,h] = contourf(L, xi, intul, [min(min(intul)):0.05e-11:max(max(intul))],'ShowText','off','edgecolor','none');
c = colorbar;
colormap jet
clabel(C,h)
hold on
for i=1:length(L)
for j=1:length(xi)
plot(L(i), xi(j), 'w.', 'LineWidth', 2, 'MarkerSize', 5)
end
end
set(gca,'clim',[min(min(intul)) max(max(intul))]);
Accepted Answer
More Answers (0)
Categories
Find more on Color and Styling in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!







