Why does LOGLOG not show logarithmic minor ticks in Y direction in MATLAB 7.13 (R2011b)?

3 vues (au cours des 30 derniers jours)
I am creating a logarithmic plot using LOGLOG as in the following example:
x = logspace(-1,2);
loglog(x,exp(x),'-s')
grid on
%%%END CODE
I would expect both X-axis and Y-axis to show logarithmic scaling in the minor ticks, but it appears the Y-axis is spaced using a linear scale.

Réponse acceptée

MathWorks Support Team
MathWorks Support Team le 30 Juil 2012
This is expected behavior. Logarithmic minor ticks are only visible within range of a decade, i.e. between 10^0 und 10^1, between 10^1 and 10^2 and so forth. If the range of the between adjacent major ticks spans multiple decades the minor ticks are spaced with a fixed distance. Referring to the example the major ticks are representing 10^10 to 10^50 and there are multiple decades between the major ticks so there is simply not enough space to visualize the minor ticks in this example.
However we can see the logarithmic scale in minor ticks when zooming into one decade:
axis([0.1 10 10 10^4])

Plus de réponses (0)

Catégories

En savoir plus sur Polar Plots dans Help Center et File Exchange

Produits


Version

R2011b

Community Treasure Hunt

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

Start Hunting!

Translated by