Matlab: fixing exponential tick labels

Sometimes for large number > 10000, Matlab/Octave axes ticks will appear as exponentials. You can fix this for your desired number of digits by:

set(gca,'YTickLabel',sprintf('%7d|',get(gca,'YTick')))

In this example, I used 7 digits.

Categories:

Updated:

Leave a Comment