changing from contour to filled on pcolor plot

3 Ansichten (letzte 30 Tage)
Giulia
Giulia am 4 Mai 2023
Beantwortet: Piyush am 18 Mai 2023
Hello :)
How can I add contours (at 0.05, 0.075, 0.1 degrees) instead of filled colours in this pcolor plot?
Thank you in advance!
Code I used for the figure is below
cm1 = brewermap(40,'RdPu');
cm1(cm1>1) = 1;
cm1(cm1<0) = 0;
LONLIMS=[-16 7.8];
LATLIMS=[47 62];
figure
m_proj('miller','lon',LONLIMS,'lat',LATLIMS);
m_pcolor(lont(1:end-1),latt(1:end-1),mean(tdh,3)')
shading flat
caxis([0.05 0.1])
colormap(cm1)
m_grid('fontsize',10);
m_gshhs_f ('patch',[.8 .8 .8],'edgecolor',[.1 .1 .1]);
cb = colorbar;
cb.Label.String = 'Horizontal Temperature gradient (\circC)';

Antworten (1)

Piyush
Piyush am 18 Mai 2023
Refer to the answer given in the following question.
It states how to overlay contour and pcolor.

Kategorien

Mehr zu Contour Plots finden Sie in Help Center und File Exchange

Tags

Community Treasure Hunt

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

Start Hunting!

Translated by