フィルターのクリア

Second set of y-axis labels for same data

2 ビュー (過去 30 日間)
Ilya Gurin
Ilya Gurin 2022 年 7 月 6 日
編集済み: Chunru 2022 年 7 月 6 日
I am plotting sensor output (voltage vs. time). I want to add a secondary y-axis that shows the same sensor output converted to physical units (not voltage). Is there a good way to do this?
I looked at the examples for yyaxis. They show how to plot dissimilar data on the same x-axis. This is not what I want!

採用された回答

Chunru
Chunru 2022 年 7 月 6 日
編集済み: Chunru 2022 年 7 月 6 日
yyaxis left
plot(randn(10,1))
ylabel('Original Unit')
xl_orig = xlim;
yl_orig = ylim;
yyaxis right
%plot(xl_orig, nan(1,2));
ylim(yl_orig*3); % 3 is factor for the new unit
ylabel('New Unit (x3)')

その他の回答 (0 件)

カテゴリ

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

タグ

製品


リリース

R2020b

Community Treasure Hunt

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

Start Hunting!

Translated by