How to convert the scientific notation to standard form

25 views (last 30 days)
Hi all, I am trying to convert the y-axis numbers from scientific notation to standard form. Below is the commands that I used, please see plot which I've attached: x=linspace(-10,10,200);
y=sin(4*x)./exp(x);
plot(x,y)
Thank you very much :)

Accepted Answer

Walter Roberson
Walter Roberson on 8 Jan 2016
If you are using R2014b or newer then I understand there are new facilities to control this.
For R2014a or earlier, you need to set the axes YTickLabel property yourself. For example,
curYTick = get(gca,'YTick');
YLabel = cellstr( num2str( curTick(:), '%f') );
set(gca, 'YTickLabel', YLabel);
Adjust the %f format code as needed.

More Answers (0)

Categories

Find more on Data Type Conversion in Help Center and File Exchange

Community Treasure Hunt

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

Start Hunting!