フィルターのクリア

how to change the y-axis ticks into 10 base power?

94 ビュー (過去 30 日間)
Mudasir Ahmed
Mudasir Ahmed 2016 年 11 月 10 日
コメント済み: bin kyu 2021 年 5 月 14 日
hi
I want to change the y-axis ticks into 10 base power format. Actually, the y-axis is the log of any data. but i need y-axis in 10^ format. I tried it manually from figure properties settings but when I change it, it shows ^ sign but I need it in the standard format. kindly help me I will be highly thankful to you
for e.g
-70 to 10^-70
-60 to 10^-60

回答 (4 件)

Jan
Jan 2016 年 11 月 10 日
Perhaps you want
H = axes;
set(H, 'YTickLabels', {'1^{-70}'})
The curly braces include the exponent in the LaTeX formatting.
  1 件のコメント
bin kyu
bin kyu 2021 年 5 月 14 日
Thank you a lot

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


KSSV
KSSV 2016 年 11 月 10 日

Michael
Michael 2016 年 11 月 10 日
If you are taking the log of some data then plotting you could just plot the raw data on a log graph using semilogy(data).
if you dont have the raw data and only the log data you can set the y ticks and the labels to be used:
yticks([-50 -60 -70 -80 -90])
yticklabels({'10E-50','10E-60','10E-70','10E-80','10E-90'})
  1 件のコメント
Mudasir Ahmed
Mudasir Ahmed 2016 年 11 月 10 日
Dear sir
thank you. But using semilogy command most of the data goes invisible I don't know why?

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


Cecilia Fleeger
Cecilia Fleeger 2018 年 11 月 29 日
I come across this post and find a solution. To get read of '^' in 10^3, for example is all about TickLabelInterpreter property.
xtick=10.^(-6:-2);
xticklab = cellstr(num2str(round(-log10(xtick(:))), '10^-^%d'));
set(gca,'XTick',xtick,'XTickLabel',xticklab,'TickLabelInterpreter','tex')

カテゴリ

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