Talk:Documentation/Calc Functions/TIME

    From The Document Foundation Wiki

    SF Comments

    (1) Summary. Reference to “current time” not understood. Suggest replacing paragraph with the following text – “Constructs a single time value based on given values of hours, minutes, and seconds.”.
    (2) Returns. Suggest replacing paragraph with the following text – “Returns a real number in the range 0.0 to 1.0 (0 ≥ x < 1) which is a date-time sequence number and is equal to the fractional part of the total time (in days) calculated by summing the given parameters. By default, the returned value is formatted as a time.”
    (3) Arguments, fourth paragraph. This paragraph is unnecessary (and possibly misleading) – it should be deleted.
    (4) Arguments, new bullet. I think it would be worth stating here that Second and Minute can be greater than 59, and that Hour can be greater than 23.
    (5) Additional details. Please delete the current contents of this section.
    (6) Additional details, new paragraph. “Calc handles date-time values as numbers, known as date-time sequence numbers. For example, 12:00 PM on 2000-01-01, converts to 36526.5 (assuming that day zero is the default 1899-12-30). The value preceding the decimal point corresponds to the date; the value following the decimal point corresponds to the time. Times are represented as a fraction of a day - for example 0.5 is half a day, or 12 hours, or 12 noon; 0.25 is a quarter of a day, or 6 am.”
    (7) Additional details, new paragraph. Please insert the correct equation for this function, obtained from the code. It is as follows – TIME = mod(((HOUR*60*60)+(MIN*60) + SEC), (60*60*24))/(60*60*24).
    (8) Additional details. As far as I can tell, Excel converts real argument values to integers. This may give different results from Calc’s approach. Should we mention this difference?
    (9) Examples, general. For all four examples, include “the” before “given”.
    (10) Examples, 2nd example. I do not really understand the second sentence and recommend deleting it. Perhaps simply restate that the function returns only the fractional part of the calculated number of days.
    (11) Examples, 3rd example. I do not really understand the second and third sentences and recommend deleting them. Perhaps simply restate that the function returns only the fractional part of the calculated number of days.
    (12) Examples, 4th example. Suggest replacing “where the formula is entered as a sequence number” with “where the cell is formatted as a number”. I do not really understand the second, third and fourth sentences of the Description and recommend deleting them. Perhaps simply restate that the function returns only the fractional part of the calculated number of days. Also, maybe state that because the cell is formatted as a number, the returned date-time sequence number is displayed in that format.

    --Stevefanning (talk) 2020-12-31T11:53:29 (UTC)

    My comments listed above addressed on 2021-02-23. --Stevefanning (talk) 2021-02-23T23:17:28 (UTC)