Re: [R] pretty for date-time?

From: Duncan Murdoch <>
Date: Thu 07 Jul 2005 - 07:44:47 EST wrote:
> pretty() works well for numbers and axTicks() can help for potting log axes,
> but has anyone written a pretty for chron objects (or other date or date-time classes)?
> It would have natural units of years, months, .., days, hours, (minutes?), and
> it would choose the appropriate unit based on the date(time) range.
> I have searched the archives and documentation to no avail.
> (I wrote one of these back in my Fortran days, and it was non-trivial, even just for dates.)

I don't think it exists (but you never know if it is in a contributed package on CRAN). However, there are methods for the generic axis() function that work on Date and POSIXct objects. (See ?axis.Date for details).

Do these do enough for you, or do you want some of the other options pretty() offers?

Duncan Murdoch

> If no-one has done it, I would be willing to work with someone more expert on production quality R to produce it.
> Thanks for any pointers,
> David L. Reiner
> Rho Trading
> 440 S. LaSalle St.
> Chicago IL 60605
> 312-362-4963
> ______________________________________________
> mailing list
> PLEASE do read the posting guide! mailing list PLEASE do read the posting guide! Received on Thu Jul 07 07:51:28 2005

This archive was generated by hypermail 2.1.8 : Fri 03 Mar 2006 - 03:33:18 EST