[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]
st: Re: time manip
--On Saturday, September 28, 2002 2:33 -0400 Jesper wrote:
As proposed, an approximation of the timing to the second is in the
daystamp variable. Since the number of seconds since the epoch is a 9 digit
number, the proposed calculations should be generated as doubles; otherwise
applying this transformation and its inverse will not yield the original
timestamp. A second off here, a second off there, and averages or other
summary stats based on these calculations will be imprecise.
I agree that it might be nice in some situations to have a format that
specified the exact time as well as the day.
So, unless you truncate it, the granularity of the timing is in the
It would be very useful to have a set of functions that allow you to work
directly with the *nix time, which allows for exact arithmetic since it is
an integer. I should not have to transform data into fractional days and
then back again to do differencing arithmetic (how long, in minutes,
between successive doses of the drug?) Those calculations using epoch time
are trivial. Then all that is needed is the ability to take a number of
seconds and format it as elapsed HH:MM[:SS], as Jesper suggests.
* For searches and help try: