How can I have two y-labels on one y axis showing both mm and degrees

1 回表示 (過去 30 日間)
Konvictus177
Konvictus177 2022 年 3 月 27 日
コメント済み: Konvictus177 2022 年 3 月 28 日
Hi,
I am plotting a surface of a cylinder using imagesc(). How can I have two y labels (mm and degrees) on one y-axis? I want mm and degrees (0-360°) to be shown on the y-axis. I do not want to use yyaxis left or something else to create a second y axis on the right.
Z = peaks;
x = linspace(0,2*pi);
y = linspace(0,2*pi);
figure
imagesc(x,y,Z)
y=ylabel('mm');
set(gca,'YDir','normal')
set(y,'FontSize',14,'FontWeight','bold');
ax = gca;
ax.FontSize = 12;
ax.FontWeight = 'bold';
I attached an image for illustration below:

回答 (1 件)

Mahmoud Ashraf
Mahmoud Ashraf 2022 年 3 月 27 日
use plotyy
  1 件のコメント
Konvictus177
Konvictus177 2022 年 3 月 28 日
I don't think I can plot 3 axes (x,y,z) with plotyy.

サインインしてコメントする。

カテゴリ

Help Center および File ExchangeAxis Labels についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by