Skip to content
Prev 63096 / 63421 Next

infelicity with axTicks

I've had a busy time the past week, so this just comes now,
(and as "top-reply", unusually for me, and this list in general..).

I've been the one adding  axTicks() to R  a long time ago,
and also  axisTicks();  these are related but really have
different goals and in particular,

-  axTicks () is in pkg {graphics}  as it applies to there only, whereas
- axisTicks() is in pkg {grDevices} as it would/should/could also apply to
              packages {grid}, {lattice} {ggplot2} etc

Their help page "title + description"s are

1)  axTicks --- Compute Axis Tickmark Locations

   Description:

     Compute pretty tickmark locations, the same way as R does
     internally.  This is only non-trivial when *log*
     coordinates are active.  By default, gives the ?at? values
     which ?axis(side)? would use.


2)  axisTicks --- Compute Pretty Axis Tick Scales

   Description:

     Compute pretty axis scales and tick mark locations, the
     same way as traditional R graphics do it.  This is
     interesting particularly for log scale axes.

Hence I guess you should really use axisTicks() rather than
axTicks() in your case.

However, even though we have tweaked both functions over time, we may not have considered all
edge cases, so would improve them where needed (and not too edgy / complicated).

Can you try to see if axisTicks() does solve your problem /
serve your purpose ?

Best regards,
Martin


--
Martin Maechler
ETH Zurich  and  R Core team