Help with plotting contour.

r=-5:.2:5; [X,Y]=meshgrid(r,r); Z=30-2*X; pcolor(Z) This is the temperature distribution. Now I want to label each color in the plot with corresponding temperature. (Say yellow corresponds to 60 degC and so on)

回答 (1 件)

Thorsten
Thorsten 2015 年 4 月 7 日

0 投票

Use colorbar to add a colorbar that relates the colors to values, as in
pcolor(peaks), colorbar

この質問は閉じられています。

製品

タグ

質問済み:

2015 年 4 月 7 日

閉鎖済み:

2021 年 8 月 20 日

Community Treasure Hunt

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

Start Hunting!

Translated by